<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>ExtUtils::MakeMaker - Create a module Makefile - Perldoc Browser</title>
    <link rel="search" href="https://perldoc.perl.org/opensearch.xml" type="application/opensearchdescription+xml" title="Perldoc Browser">
    <link rel="canonical" href="https://perldoc.perl.org/ExtUtils::MakeMaker">
    <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css" integrity="sha384-JcKb8q3iqJ61gNV9KGb8thSsNjpSL0n8PARn9HuZOnIxN0hoP+VmmDGMN5t9UJ0Z" crossorigin="anonymous">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/10.5.0/styles/stackoverflow-light.min.css" integrity="sha512-cG1IdFxqipi3gqLmksLtuk13C+hBa57a6zpWxMeoY3Q9O6ooFxq50DayCdm0QrDgZjMUn23z/0PMZlgft7Yp5Q==" crossorigin="anonymous" />
    <style>
      body {
        background: #f4f4f5;
        color: #020202;
      }
      .navbar-dark {
        background-image: -webkit-linear-gradient(top, #005f85 0, #002e49 100%);
        background-image: -o-linear-gradient(top, #005f85 0, #002e49 100%);
        background-image: linear-gradient(to bottom, #005f85 0, #002e49 100%);
        filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff005f85', endColorstr='#ff002e49', GradientType=0);
        background-repeat: repeat-x;
      }
      .navbar-dark .navbar-nav .nav-link,
      .navbar-dark .navbar-nav .nav-link:focus { color: #fff }
      .navbar-dark .navbar-nav .nav-link:hover { color: #ffef68 }
      #wrapperlicious {
        margin: 0 auto;
        font: 0.9em 'Helvetica Neue', Helvetica, sans-serif;
        font-weight: normal;
        line-height: 1.5em;
        margin: 0;
        padding: 0;
      }
      #wrapperlicious h1 { font-size: 1.5em }
      #wrapperlicious h2 { font-size: 1.3em }
      #wrapperlicious h3 { font-size: 1.1em }
      #wrapperlicious h4 { font-size: 0.9em }
      #wrapperlicious h1, #wrapperlicious h2, #wrapperlicious h3,
      #wrapperlicious h4, #wrapperlicious dt {
        color: #020202;
        margin-top: 1em;
        margin-bottom: 1em;
        position: relative;
        font-weight: bold;
      }
      #wrapperlicious a { color: inherit; text-decoration: underline }
      #wrapperlicious #toc { text-decoration: none }
      #wrapperlicious a:hover { color: #2a2a2a }
      #wrapperlicious a img { border: 0 }
      #wrapperlicious :not(pre) > code {
        color: inherit;
        background-color: rgba(0, 0, 0, 0.04);
        border-radius: 3px;
        font: 0.9em Consolas, Menlo, Monaco, monospace;
        padding: 0.3em;
      }
      #wrapperlicious dd {
        margin: 0;
        margin-left: 2em;
      }
      #wrapperlicious dt {
        color: #2a2a2a;
        font-weight: bold;
        margin-left: 0.9em;
      }
      #wrapperlicious p {
        margin-bottom: 1em;
        margin-top: 1em;
      }
      #wrapperlicious li > p {
        margin-bottom: 0;
        margin-top: 0;
      }
      #wrapperlicious pre {
        border: 1px solid #c1c1c1;
        border-radius: 3px;
        font: 100% Consolas, Menlo, Monaco, monospace;
        margin-bottom: 1em;
        margin-top: 1em;
      }
      #wrapperlicious pre > code {
        display: block;
        background-color: #f6f6f6;
        font: 0.9em Consolas, Menlo, Monaco, monospace;
        line-height: 1.5em;
        text-align: left;
        white-space: pre;
        padding: 1em;
      }
      #wrapperlicious dl, #wrapperlicious ol, #wrapperlicious ul {
        margin-bottom: 1em;
        margin-top: 1em;
      }
      #wrapperlicious ul {
        list-style-type: square;
      }
      #wrapperlicious ul ul {
        margin-bottom: 0px;
        margin-top: 0px;
      }
      #footer {
        font-size: 0.8em;
        padding-top: 0.5em;
        text-align: center;
      }
      #more {
        display: inline;
        font-size: 0.8em;
      }
      #perldocdiv {
        background-color: #fff;
        border: 1px solid #c1c1c1;
        border-bottom-left-radius: 5px;
        border-bottom-right-radius: 5px;
        margin-left: auto;
        margin-right: auto;
        padding: 3em;
        padding-top: 1em;
        max-width: 960px;
      }
      #moduleversion { float: right }
      #wrapperlicious .leading-notice {
        font-style: italic;
        padding-left: 1em;
        margin-top: 1em;
        margin-bottom: 1em;
      }
      #wrapperlicious .permalink {
        display: none;
        left: -0.75em;
        position: absolute;
        padding-right: 0.25em;
        text-decoration: none;
      }
      #wrapperlicious h1:hover .permalink, #wrapperlicious h2:hover .permalink,
      #wrapperlicious h3:hover .permalink, #wrapperlicious h4:hover .permalink,
      #wrapperlicious dt:hover .permalink {
        display: block;
      }
    </style>
    <!-- Global site tag (gtag.js) - Google Analytics -->
    <script async src="https://www.googletagmanager.com/gtag/js?id=G-KVNWBNT5FB"></script>
    <script>
      window.dataLayer = window.dataLayer || [];
      function gtag(){dataLayer.push(arguments);}
      gtag('js', new Date());

      gtag('config', 'G-KVNWBNT5FB');
      gtag('config', 'UA-50555-3');
    </script>
  </head>
  <body>
    <nav class="navbar navbar-expand-md navbar-dark bg-dark justify-content-between">
  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
    <span class="navbar-toggler-icon"></span>
  </button>
  <a class="navbar-brand" href="https://perldoc.perl.org/">Perldoc Browser</a>
  <div class="collapse navbar-collapse" id="navbarNav">
    <ul class="navbar-nav mr-auto">
      <li class="nav-item dropdown text-nowrap">
        <a class="nav-link dropdown-toggle" href="./ExtUtils::MakeMaker.html#" id="dropdownlink-stable" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">5.35.0</a>
        <div class="dropdown-menu" aria-labelledby="dropdownlink-stable">
          <a class="dropdown-item" href="https://perldoc.perl.org/ExtUtils::MakeMaker">Latest</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.38.2/ExtUtils::MakeMaker">5.38.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.38.1/ExtUtils::MakeMaker">5.38.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.38.0/ExtUtils::MakeMaker">5.38.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.36.3/ExtUtils::MakeMaker">5.36.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.36.2/ExtUtils::MakeMaker">5.36.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.36.1/ExtUtils::MakeMaker">5.36.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.36.0/ExtUtils::MakeMaker">5.36.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.34.3/ExtUtils::MakeMaker">5.34.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.34.2/ExtUtils::MakeMaker">5.34.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.34.1/ExtUtils::MakeMaker">5.34.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.34.0/ExtUtils::MakeMaker">5.34.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.32.1/ExtUtils::MakeMaker">5.32.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.32.0/ExtUtils::MakeMaker">5.32.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.30.3/ExtUtils::MakeMaker">5.30.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.30.2/ExtUtils::MakeMaker">5.30.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.30.1/ExtUtils::MakeMaker">5.30.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.30.0/ExtUtils::MakeMaker">5.30.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.28.3/ExtUtils::MakeMaker">5.28.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.28.2/ExtUtils::MakeMaker">5.28.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.28.1/ExtUtils::MakeMaker">5.28.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.28.0/ExtUtils::MakeMaker">5.28.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.26.3/ExtUtils::MakeMaker">5.26.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.26.2/ExtUtils::MakeMaker">5.26.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.26.1/ExtUtils::MakeMaker">5.26.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.26.0/ExtUtils::MakeMaker">5.26.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.24.4/ExtUtils::MakeMaker">5.24.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.24.3/ExtUtils::MakeMaker">5.24.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.24.2/ExtUtils::MakeMaker">5.24.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.24.1/ExtUtils::MakeMaker">5.24.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.24.0/ExtUtils::MakeMaker">5.24.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.22.4/ExtUtils::MakeMaker">5.22.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.22.3/ExtUtils::MakeMaker">5.22.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.22.2/ExtUtils::MakeMaker">5.22.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.22.1/ExtUtils::MakeMaker">5.22.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.22.0/ExtUtils::MakeMaker">5.22.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.20.3/ExtUtils::MakeMaker">5.20.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.20.2/ExtUtils::MakeMaker">5.20.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.20.1/ExtUtils::MakeMaker">5.20.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.20.0/ExtUtils::MakeMaker">5.20.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.18.4/ExtUtils::MakeMaker">5.18.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.18.3/ExtUtils::MakeMaker">5.18.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.18.2/ExtUtils::MakeMaker">5.18.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.18.1/ExtUtils::MakeMaker">5.18.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.18.0/ExtUtils::MakeMaker">5.18.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.16.3/ExtUtils::MakeMaker">5.16.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.16.2/ExtUtils::MakeMaker">5.16.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.16.1/ExtUtils::MakeMaker">5.16.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.16.0/ExtUtils::MakeMaker">5.16.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.14.4/ExtUtils::MakeMaker">5.14.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.14.3/ExtUtils::MakeMaker">5.14.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.14.2/ExtUtils::MakeMaker">5.14.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.14.1/ExtUtils::MakeMaker">5.14.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.14.0/ExtUtils::MakeMaker">5.14.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.12.5/ExtUtils::MakeMaker">5.12.5</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.12.4/ExtUtils::MakeMaker">5.12.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.12.3/ExtUtils::MakeMaker">5.12.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.12.2/ExtUtils::MakeMaker">5.12.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.12.1/ExtUtils::MakeMaker">5.12.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.12.0/ExtUtils::MakeMaker">5.12.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.10.1/ExtUtils::MakeMaker">5.10.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.10.0/ExtUtils::MakeMaker">5.10.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.9/ExtUtils::MakeMaker">5.8.9</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.8/ExtUtils::MakeMaker">5.8.8</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.7/ExtUtils::MakeMaker">5.8.7</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.6/ExtUtils::MakeMaker">5.8.6</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.5/ExtUtils::MakeMaker">5.8.5</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.4/ExtUtils::MakeMaker">5.8.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.3/ExtUtils::MakeMaker">5.8.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.2/ExtUtils::MakeMaker">5.8.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.1/ExtUtils::MakeMaker">5.8.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.8.0/ExtUtils::MakeMaker">5.8.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.6.2/ExtUtils::MakeMaker">5.6.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.6.1/ExtUtils::MakeMaker">5.6.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.6.0/ExtUtils::MakeMaker">5.6.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.005_04/ExtUtils::MakeMaker">5.005_04</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.005_03/ExtUtils::MakeMaker">5.005_03</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.005_02/ExtUtils::MakeMaker">5.005_02</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.005_01/ExtUtils::MakeMaker">5.005_01</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.005/ExtUtils::MakeMaker">5.005</a>
        </div>
      </li>
      <li class="nav-item dropdown text-nowrap">
        <a class="nav-link dropdown-toggle" href="./ExtUtils::MakeMaker.html#" id="dropdownlink-dev" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Dev</a>
        <div class="dropdown-menu" aria-labelledby="dropdownlink-dev">
          <a class="dropdown-item" href="https://perldoc.perl.org/blead/ExtUtils::MakeMaker">blead</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.39.6/ExtUtils::MakeMaker">5.39.6</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.39.5/ExtUtils::MakeMaker">5.39.5</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.39.4/ExtUtils::MakeMaker">5.39.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.39.3/ExtUtils::MakeMaker">5.39.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.39.2/ExtUtils::MakeMaker">5.39.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.39.1/ExtUtils::MakeMaker">5.39.1</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.38.0-RC2/ExtUtils::MakeMaker">5.38.0-RC2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.38.0-RC1/ExtUtils::MakeMaker">5.38.0-RC1</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.11/ExtUtils::MakeMaker">5.37.11</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.10/ExtUtils::MakeMaker">5.37.10</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.9/ExtUtils::MakeMaker">5.37.9</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.8/ExtUtils::MakeMaker">5.37.8</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.7/ExtUtils::MakeMaker">5.37.7</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.6/ExtUtils::MakeMaker">5.37.6</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.5/ExtUtils::MakeMaker">5.37.5</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.4/ExtUtils::MakeMaker">5.37.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.3/ExtUtils::MakeMaker">5.37.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.2/ExtUtils::MakeMaker">5.37.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.1/ExtUtils::MakeMaker">5.37.1</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.37.0/ExtUtils::MakeMaker">5.37.0</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.11/ExtUtils::MakeMaker">5.35.11</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.10/ExtUtils::MakeMaker">5.35.10</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.9/ExtUtils::MakeMaker">5.35.9</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.8/ExtUtils::MakeMaker">5.35.8</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.7/ExtUtils::MakeMaker">5.35.7</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.6/ExtUtils::MakeMaker">5.35.6</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.5/ExtUtils::MakeMaker">5.35.5</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.4/ExtUtils::MakeMaker">5.35.4</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.3/ExtUtils::MakeMaker">5.35.3</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.2/ExtUtils::MakeMaker">5.35.2</a>
          <a class="dropdown-item" href="https://perldoc.perl.org/5.35.1/ExtUtils::MakeMaker">5.35.1</a>
          <a class="dropdown-item active" href="./ExtUtils::MakeMaker.html">5.35.0</a>
        </div>
      </li>
      <li class="nav-item dropdown text-nowrap">
        <a class="nav-link dropdown-toggle" href="./ExtUtils::MakeMaker.html#" id="dropdownlink-nav" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Documentation</a>
        <div class="dropdown-menu" aria-labelledby="dropdownlink-nav">
          <a class="dropdown-item" href="perl.html">Perl</a>
          <a class="dropdown-item" href="perlintro.html">Intro</a>
          <a class="dropdown-item" href="perl.html#Tutorials">Tutorials</a>
          <a class="dropdown-item" href="perlfaq.html">FAQs</a>
          <a class="dropdown-item" href="perl.html#Reference-Manual">Reference</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="perlop.html">Operators</a>
          <a class="dropdown-item" href="functions.html">Functions</a>
          <a class="dropdown-item" href="variables.html">Variables</a>
          <a class="dropdown-item" href="modules.html">Modules</a>
          <a class="dropdown-item" href="perlutil.html">Utilities</a>
          <div class="dropdown-divider"></div>
          <a class="dropdown-item" href="perlcommunity.html">Community</a>
          <a class="dropdown-item" href="perlhist.html">History</a>
        </div>
      </li>
    </ul>
    <ul class="navbar-nav">
      <script>
        function set_expand (expand) {
          var perldocdiv = document.getElementById('perldocdiv');
          var width = window.getComputedStyle(perldocdiv).getPropertyValue('max-width');
          var expanded = (width == '' || width == 'none') ? true : false;
          if (expand === null) {
            expand = !expanded;
          }
          if ((expand && !expanded) || (!expand && expanded)) {
            perldocdiv.style.setProperty('max-width', expand ? 'none' : '960px');
            var button_classlist = document.getElementById('content-expand-button').classList;
            if (expand) {
              button_classlist.add('btn-light');
              button_classlist.remove('btn-outline-light');
            } else {
              button_classlist.add('btn-outline-light');
              button_classlist.remove('btn-light');
            }
          }
          return expand;
        }
        function toggle_expand () {
          var expand = set_expand(null);
          document.cookie = 'perldoc_expand=' + (expand ? 1 : 0) + '; path=/; expires=Tue, 19 Jan 2038 03:14:07 UTC';
        }
        function read_expand () {
          return document.cookie.split(';').some(function (item) { return item.indexOf('perldoc_expand=1') >= 0 });
        }
        if (document.readyState === 'loading') {
          document.addEventListener('DOMContentLoaded', function () {
            if (read_expand()) {
              set_expand(true);
            }
          });
        } else if (read_expand()) {
          set_expand(true);
        }
      </script>
      <button id="content-expand-button" type="button" class="btn btn-outline-light d-none d-lg-inline-block mr-2" onclick="toggle_expand()">Expand</button>
    <ul>
    <form class="form-inline" method="get" action="https://perldoc.perl.org/5.35.0/search">
      <input class="form-control mr-3" type="search" name="q" placeholder="Search" aria-label="Search">
    </form>
  </div>
</nav>

    <div id="wrapperlicious" class="container-fluid">
      <div id="perldocdiv">
        <div id="links">
          <a href="./ExtUtils::MakeMaker.html">ExtUtils::MakeMaker</a>
          <div id="more">
            (<a href="./ExtUtils::MakeMaker.txt">source</a>,
            <a href="https://metacpan.org/pod/ExtUtils::MakeMaker">CPAN</a>)
          </div>
            <div id="moduleversion">version 7.62</div>
        </div>
        <div class="leading-notice">
          You are viewing the version of this documentation from Perl 5.35.0.
            This is a development version of Perl.
        </div>
        <h1><a id="toc">CONTENTS</a></h1>
                  <ul>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#NAME">NAME</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#SYNOPSIS">SYNOPSIS</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#DESCRIPTION">DESCRIPTION</a>
                            <ul>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#How-To-Write-A-Makefile.PL">How To Write A Makefile.PL</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#Default-Makefile-Behaviour">Default Makefile Behaviour</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#make-test">make test</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#make-testdb">make testdb</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#make-install">make install</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#INSTALL_BASE">INSTALL_BASE</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#PREFIX-and-LIB-attribute">PREFIX and LIB attribute</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#AFS-users">AFS users</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#Static-Linking-of-a-new-Perl-Binary">Static Linking of a new Perl Binary</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#Determination-of-Perl-Library-and-Installation-Locations">Determination of Perl Library and Installation Locations</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#Which-architecture-dependent-directory?">Which architecture dependent directory?</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#Using-Attributes-and-Parameters">Using Attributes and Parameters</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#Additional-lowercase-attributes">Additional lowercase attributes</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#Overriding-MakeMaker-Methods">Overriding MakeMaker Methods</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#The-End-Of-Cargo-Cult-Programming">The End Of Cargo Cult Programming</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#Hintsfile-support">Hintsfile support</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#Distribution-Support">Distribution Support</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#Module-Meta-Data-(META-and-MYMETA)">Module Meta-Data (META and MYMETA)</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#Disabling-an-extension">Disabling an extension</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#Other-Handy-Functions">Other Handy Functions</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#Supported-versions-of-Perl">Supported versions of Perl</a>
              </li>
          </ul>

              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#ENVIRONMENT">ENVIRONMENT</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#SEE-ALSO">SEE ALSO</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#AUTHORS">AUTHORS</a>
              </li>
              <li>
                <a class="text-decoration-none" href="./ExtUtils::MakeMaker.html#LICENSE1">LICENSE</a>
              </li>
          </ul>

      <h1 id="NAME"><a class="permalink" href="./ExtUtils::MakeMaker.html#NAME">#</a>NAME</h1>

<p>ExtUtils::MakeMaker - Create a module Makefile</p>

<h1 id="SYNOPSIS"><a class="permalink" href="./ExtUtils::MakeMaker.html#SYNOPSIS">#</a>SYNOPSIS</h1>

<pre><code>use ExtUtils::MakeMaker;

WriteMakefile(
    NAME              =&gt; &quot;Foo::Bar&quot;,
    VERSION_FROM      =&gt; &quot;lib/Foo/Bar.pm&quot;,
);</code></pre>

<h1 id="DESCRIPTION"><a class="permalink" href="./ExtUtils::MakeMaker.html#DESCRIPTION">#</a>DESCRIPTION</h1>

<p>This utility is designed to write a Makefile for an extension module from a Makefile.PL. It is based on the Makefile.SH model provided by Andy Dougherty and the perl5-porters.</p>

<p>It splits the task of generating the Makefile into several subroutines that can be individually overridden. Each subroutine returns the text it wishes to have written to the Makefile.</p>

<p>As there are various Make programs with incompatible syntax, which use operating system shells, again with incompatible syntax, it is important for users of this module to know which flavour of Make a Makefile has been written for so they&#39;ll use the correct one and won&#39;t have to face the possibly bewildering errors resulting from using the wrong one.</p>

<p>On POSIX systems, that program will likely be GNU Make; on Microsoft Windows, it will be either Microsoft NMake, DMake or GNU Make. See the section on the <a href="./ExtUtils::MakeMaker.html#MAKE">&quot;MAKE&quot;</a> parameter for details.</p>

<p>ExtUtils::MakeMaker (EUMM) is object oriented. Each directory below the current directory that contains a Makefile.PL is treated as a separate object. This makes it possible to write an unlimited number of Makefiles with a single invocation of WriteMakefile().</p>

<p>All inputs to WriteMakefile are Unicode characters, not just octets. EUMM seeks to handle all of these correctly. It is currently still not possible to portably use Unicode characters in module names, because this requires Perl to handle Unicode filenames, which is not yet the case on Windows.</p>

<p>See <a href="./ExtUtils::MakeMaker::FAQ.html">ExtUtils::MakeMaker::FAQ</a> for details of the design and usage.</p>

<h2 id="How-To-Write-A-Makefile.PL"><a class="permalink" href="./ExtUtils::MakeMaker.html#How-To-Write-A-Makefile.PL">#</a><a id="How"></a>How To Write A Makefile.PL</h2>

<p>See <a href="./ExtUtils::MakeMaker::Tutorial.html">ExtUtils::MakeMaker::Tutorial</a>.</p>

<p>The long answer is the rest of the manpage :-)</p>

<h2 id="Default-Makefile-Behaviour"><a class="permalink" href="./ExtUtils::MakeMaker.html#Default-Makefile-Behaviour">#</a><a id="Default"></a>Default Makefile Behaviour</h2>

<p>The generated Makefile enables the user of the extension to invoke</p>

<pre><code class="plaintext">perl Makefile.PL # optionally &quot;perl Makefile.PL verbose&quot;
make
make test        # optionally set TEST_VERBOSE=1
make install     # See below</code></pre>

<p>The Makefile to be produced may be altered by adding arguments of the form <code>KEY=VALUE</code>. E.g.</p>

<pre><code class="plaintext">perl Makefile.PL INSTALL_BASE=~</code></pre>

<p>Other interesting targets in the generated Makefile are</p>

<pre><code class="plaintext">make config     # to check if the Makefile is up-to-date
make clean      # delete local temp files (Makefile gets renamed)
make realclean  # delete derived files (including ./blib)
make ci         # check in all the files in the MANIFEST file
make dist       # see below the Distribution Support section</code></pre>

<h2 id="make-test"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-test">#</a><a id="make"></a>make test</h2>

<p>MakeMaker checks for the existence of a file named <i>test.pl</i> in the current directory, and if it exists it executes the script with the proper set of perl <code>-I</code> options.</p>

<p>MakeMaker also checks for any files matching glob(&quot;t/*.t&quot;). It will execute all matching files in alphabetical order via the <a href="./Test::Harness.html">Test::Harness</a> module with the <code>-I</code> switches set correctly.</p>

<p>You can also organize your tests within subdirectories in the <i>t/</i> directory. To do so, use the <i>test</i> directive in your <i>Makefile.PL</i>. For example, if you had tests in:</p>

<pre><code class="plaintext">t/foo
t/foo/bar</code></pre>

<p>You could tell make to run tests in both of those directories with the following directives:</p>

<pre><code class="plaintext">test =&gt; {TESTS =&gt; &#39;t/*/*.t t/*/*/*.t&#39;}
test =&gt; {TESTS =&gt; &#39;t/foo/*.t t/foo/bar/*.t&#39;}</code></pre>

<p>The first will run all test files in all first-level subdirectories and all subdirectories they contain. The second will run tests in only the <i>t/foo</i> and <i>t/foo/bar</i>.</p>

<p>If you&#39;d like to see the raw output of your tests, set the <code>TEST_VERBOSE</code> variable to true.</p>

<pre><code class="plaintext">make test TEST_VERBOSE=1</code></pre>

<p>If you want to run particular test files, set the <code>TEST_FILES</code> variable. It is possible to use globbing with this mechanism.</p>

<pre><code class="plaintext">make test TEST_FILES=&#39;t/foobar.t t/dagobah*.t&#39;</code></pre>

<p>Windows users who are using <code>nmake</code> should note that due to a bug in <code>nmake</code>, when specifying <code>TEST_FILES</code> you must use back-slashes instead of forward-slashes.</p>

<pre><code class="plaintext">nmake test TEST_FILES=&#39;t\foobar.t t\dagobah*.t&#39;</code></pre>

<h2 id="make-testdb"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-testdb">#</a><a id="make1"></a>make testdb</h2>

<p>A useful variation of the above is the target <code>testdb</code>. It runs the test under the Perl debugger (see <a href="perldebug.html">perldebug</a>). If the file <i>test.pl</i> exists in the current directory, it is used for the test.</p>

<p>If you want to debug some other testfile, set the <code>TEST_FILE</code> variable thusly:</p>

<pre><code class="plaintext">make testdb TEST_FILE=t/mytest.t</code></pre>

<p>By default the debugger is called using <code>-d</code> option to perl. If you want to specify some other option, set the <code>TESTDB_SW</code> variable:</p>

<pre><code class="plaintext">make testdb TESTDB_SW=-Dx</code></pre>

<h2 id="make-install"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-install">#</a><a id="make2"></a>make install</h2>

<p>make alone puts all relevant files into directories that are named by the macros INST_LIB, INST_ARCHLIB, INST_SCRIPT, INST_MAN1DIR and INST_MAN3DIR. All these default to something below ./blib if you are <i>not</i> building below the perl source directory. If you <i>are</i> building below the perl source, INST_LIB and INST_ARCHLIB default to ../../lib, and INST_SCRIPT is not defined.</p>

<p>The <i>install</i> target of the generated Makefile copies the files found below each of the INST_* directories to their INSTALL* counterparts. Which counterparts are chosen depends on the setting of INSTALLDIRS according to the following table:</p>

<pre><code class="plaintext">                               INSTALLDIRS set to
                         perl        site          vendor

               PERLPREFIX      SITEPREFIX          VENDORPREFIX
INST_ARCHLIB   INSTALLARCHLIB  INSTALLSITEARCH     INSTALLVENDORARCH
INST_LIB       INSTALLPRIVLIB  INSTALLSITELIB      INSTALLVENDORLIB
INST_BIN       INSTALLBIN      INSTALLSITEBIN      INSTALLVENDORBIN
INST_SCRIPT    INSTALLSCRIPT   INSTALLSITESCRIPT   INSTALLVENDORSCRIPT
INST_MAN1DIR   INSTALLMAN1DIR  INSTALLSITEMAN1DIR  INSTALLVENDORMAN1DIR
INST_MAN3DIR   INSTALLMAN3DIR  INSTALLSITEMAN3DIR  INSTALLVENDORMAN3DIR</code></pre>

<p>The INSTALL... macros in turn default to their %Config ($Config{installprivlib}, $Config{installarchlib}, etc.) counterparts.</p>

<p>You can check the values of these variables on your system with</p>

<pre><code class="plaintext">perl &#39;-V:install.*&#39;</code></pre>

<p>And to check the sequence in which the library directories are searched by perl, run</p>

<pre><code>perl -le &#39;print join $/, @INC&#39;</code></pre>

<p>Sometimes older versions of the module you&#39;re installing live in other directories in @INC. Because Perl loads the first version of a module it finds, not the newest, you might accidentally get one of these older versions even after installing a brand new version. To delete <i>all other versions of the module you&#39;re installing</i> (not simply older ones) set the <code>UNINST</code> variable.</p>

<pre><code class="plaintext">make install UNINST=1</code></pre>

<h2 id="INSTALL_BASE"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALL_BASE">#</a>INSTALL_BASE</h2>

<p>INSTALL_BASE can be passed into Makefile.PL to change where your module will be installed. INSTALL_BASE is more like what everyone else calls &quot;prefix&quot; than PREFIX is.</p>

<p>To have everything installed in your home directory, do the following.</p>

<pre><code class="plaintext"># Unix users, INSTALL_BASE=~ works fine
perl Makefile.PL INSTALL_BASE=/path/to/your/home/dir</code></pre>

<p>Like PREFIX, it sets several INSTALL* attributes at once. Unlike PREFIX it is easy to predict where the module will end up. The installation pattern looks like this:</p>

<pre><code>INSTALLARCHLIB     INSTALL_BASE/lib/perl5/$Config{archname}
INSTALLPRIVLIB     INSTALL_BASE/lib/perl5
INSTALLBIN         INSTALL_BASE/bin
INSTALLSCRIPT      INSTALL_BASE/bin
INSTALLMAN1DIR     INSTALL_BASE/man/man1
INSTALLMAN3DIR     INSTALL_BASE/man/man3</code></pre>

<p>INSTALL_BASE in MakeMaker and <code>--install_base</code> in Module::Build (as of 0.28) install to the same location. If you want MakeMaker and Module::Build to install to the same location simply set INSTALL_BASE and <code>--install_base</code> to the same location.</p>

<p>INSTALL_BASE was added in 6.31.</p>

<h2 id="PREFIX-and-LIB-attribute"><a class="permalink" href="./ExtUtils::MakeMaker.html#PREFIX-and-LIB-attribute">#</a><a id="PREFIX1"></a>PREFIX and LIB attribute</h2>

<p>PREFIX and LIB can be used to set several INSTALL* attributes in one go. Here&#39;s an example for installing into your home directory.</p>

<pre><code class="plaintext"># Unix users, PREFIX=~ works fine
perl Makefile.PL PREFIX=/path/to/your/home/dir</code></pre>

<p>This will install all files in the module under your home directory, with man pages and libraries going into an appropriate place (usually ~/man and ~/lib). How the exact location is determined is complicated and depends on how your Perl was configured. INSTALL_BASE works more like what other build systems call &quot;prefix&quot; than PREFIX and we recommend you use that instead.</p>

<p>Another way to specify many INSTALL directories with a single parameter is LIB.</p>

<pre><code class="plaintext">perl Makefile.PL LIB=~/lib</code></pre>

<p>This will install the module&#39;s architecture-independent files into ~/lib, the architecture-dependent files into ~/lib/$archname.</p>

<p>Note, that in both cases the tilde expansion is done by MakeMaker, not by perl by default, nor by make.</p>

<p>Conflicts between parameters LIB, PREFIX and the various INSTALL* arguments are resolved so that:</p>

<ul>

<li><p>setting LIB overrides any setting of INSTALLPRIVLIB, INSTALLARCHLIB, INSTALLSITELIB, INSTALLSITEARCH (and they are not affected by PREFIX);</p>

</li>
<li><p>without LIB, setting PREFIX replaces the initial <code>$Config{prefix}</code> part of those INSTALL* arguments, even if the latter are explicitly set (but are set to still start with <code>$Config{prefix}</code>).</p>

</li>
</ul>

<p>If the user has superuser privileges, and is not working on AFS or relatives, then the defaults for INSTALLPRIVLIB, INSTALLARCHLIB, INSTALLSCRIPT, etc. will be appropriate, and this incantation will be the best:</p>

<pre><code>perl Makefile.PL;
make;
make test
make install</code></pre>

<p>make install by default writes some documentation of what has been done into the file <code>$(INSTALLARCHLIB)/perllocal.pod</code>. This feature can be bypassed by calling make pure_install.</p>

<h2 id="AFS-users"><a class="permalink" href="./ExtUtils::MakeMaker.html#AFS-users">#</a><a id="AFS"></a>AFS users</h2>

<p>will have to specify the installation directories as these most probably have changed since perl itself has been installed. They will have to do this by calling</p>

<pre><code class="plaintext">perl Makefile.PL INSTALLSITELIB=/afs/here/today \
    INSTALLSCRIPT=/afs/there/now INSTALLMAN3DIR=/afs/for/manpages
make</code></pre>

<p>Be careful to repeat this procedure every time you recompile an extension, unless you are sure the AFS installation directories are still valid.</p>

<h2 id="Static-Linking-of-a-new-Perl-Binary"><a class="permalink" href="./ExtUtils::MakeMaker.html#Static-Linking-of-a-new-Perl-Binary">#</a><a id="Static"></a>Static Linking of a new Perl Binary</h2>

<p>An extension that is built with the above steps is ready to use on systems supporting dynamic loading. On systems that do not support dynamic loading, any newly created extension has to be linked together with the available resources. MakeMaker supports the linking process by creating appropriate targets in the Makefile whenever an extension is built. You can invoke the corresponding section of the makefile with</p>

<pre><code class="plaintext">make perl</code></pre>

<p>That produces a new perl binary in the current directory with all extensions linked in that can be found in INST_ARCHLIB, SITELIBEXP, and PERL_ARCHLIB. To do that, MakeMaker writes a new Makefile, on UNIX, this is called <i>Makefile.aperl</i> (may be system dependent). If you want to force the creation of a new perl, it is recommended that you delete this <i>Makefile.aperl</i>, so the directories are searched through for linkable libraries again.</p>

<p>The binary can be installed into the directory where perl normally resides on your machine with</p>

<pre><code class="plaintext">make inst_perl</code></pre>

<p>To produce a perl binary with a different name than <code>perl</code>, either say</p>

<pre><code class="plaintext">perl Makefile.PL MAP_TARGET=myperl
make myperl
make inst_perl</code></pre>

<p>or say</p>

<pre><code class="plaintext">perl Makefile.PL
make myperl MAP_TARGET=myperl
make inst_perl MAP_TARGET=myperl</code></pre>

<p>In any case you will be prompted with the correct invocation of the <code>inst_perl</code> target that installs the new binary into INSTALLBIN.</p>

<p>make inst_perl by default writes some documentation of what has been done into the file <code>$(INSTALLARCHLIB)/perllocal.pod</code>. This can be bypassed by calling make pure_inst_perl.</p>

<p>Warning: the inst_perl: target will most probably overwrite your existing perl binary. Use with care!</p>

<p>Sometimes you might want to build a statically linked perl although your system supports dynamic loading. In this case you may explicitly set the linktype with the invocation of the Makefile.PL or make:</p>

<pre><code class="plaintext">perl Makefile.PL LINKTYPE=static    # recommended</code></pre>

<p>or</p>

<pre><code class="plaintext">make LINKTYPE=static                # works on most systems</code></pre>

<h2 id="Determination-of-Perl-Library-and-Installation-Locations"><a class="permalink" href="./ExtUtils::MakeMaker.html#Determination-of-Perl-Library-and-Installation-Locations">#</a><a id="Determination"></a>Determination of Perl Library and Installation Locations</h2>

<p>MakeMaker needs to know, or to guess, where certain things are located. Especially INST_LIB and INST_ARCHLIB (where to put the files during the make(1) run), PERL_LIB and PERL_ARCHLIB (where to read existing modules from), and PERL_INC (header files and <code>libperl*.*</code>).</p>

<p>Extensions may be built either using the contents of the perl source directory tree or from the installed perl library. The recommended way is to build extensions after you have run &#39;make install&#39; on perl itself. You can do that in any directory on your hard disk that is not below the perl source tree. The support for extensions below the ext directory of the perl distribution is only good for the standard extensions that come with perl.</p>

<p>If an extension is being built below the <code>ext/</code> directory of the perl source then MakeMaker will set PERL_SRC automatically (e.g., <code>../..</code>). If PERL_SRC is defined and the extension is recognized as a standard extension, then other variables default to the following:</p>

<pre><code class="plaintext">PERL_INC     = PERL_SRC
PERL_LIB     = PERL_SRC/lib
PERL_ARCHLIB = PERL_SRC/lib
INST_LIB     = PERL_LIB
INST_ARCHLIB = PERL_ARCHLIB</code></pre>

<p>If an extension is being built away from the perl source then MakeMaker will leave PERL_SRC undefined and default to using the installed copy of the perl library. The other variables default to the following:</p>

<pre><code>PERL_INC     = $archlibexp/CORE
PERL_LIB     = $privlibexp
PERL_ARCHLIB = $archlibexp
INST_LIB     = ./blib/lib
INST_ARCHLIB = ./blib/arch</code></pre>

<p>If perl has not yet been installed then PERL_SRC can be defined on the command line as shown in the previous section.</p>

<h2 id="Which-architecture-dependent-directory?"><a class="permalink" href="./ExtUtils::MakeMaker.html#Which-architecture-dependent-directory?">#</a><a id="Which"></a><a id="Which-architecture-dependent-directory"></a>Which architecture dependent directory?</h2>

<p>If you don&#39;t want to keep the defaults for the INSTALL* macros, MakeMaker helps you to minimize the typing needed: the usual relationship between INSTALLPRIVLIB and INSTALLARCHLIB is determined by Configure at perl compilation time. MakeMaker supports the user who sets INSTALLPRIVLIB. If INSTALLPRIVLIB is set, but INSTALLARCHLIB not, then MakeMaker defaults the latter to be the same subdirectory of INSTALLPRIVLIB as Configure decided for the counterparts in %Config, otherwise it defaults to INSTALLPRIVLIB. The same relationship holds for INSTALLSITELIB and INSTALLSITEARCH.</p>

<p>MakeMaker gives you much more freedom than needed to configure internal variables and get different results. It is worth mentioning that make(1) also lets you configure most of the variables that are used in the Makefile. But in the majority of situations this will not be necessary, and should only be done if the author of a package recommends it (or you know what you&#39;re doing).</p>

<h2 id="Using-Attributes-and-Parameters"><a class="permalink" href="./ExtUtils::MakeMaker.html#Using-Attributes-and-Parameters">#</a><a id="Using"></a>Using Attributes and Parameters</h2>

<p>The following attributes may be specified as arguments to WriteMakefile() or as NAME=VALUE pairs on the command line. Attributes that became available with later versions of MakeMaker are indicated.</p>

<p>In order to maintain portability of attributes with older versions of MakeMaker you may want to use <a href="./App::EUMM::Upgrade.html">App::EUMM::Upgrade</a> with your <code>Makefile.PL</code>.</p>

<dl>

<dt id="ABSTRACT"><a class="permalink" href="./ExtUtils::MakeMaker.html#ABSTRACT">#</a>ABSTRACT</dt>
<dd>

<p>One line description of the module. Will be included in PPD file.</p>

</dd>
<dt id="ABSTRACT_FROM"><a class="permalink" href="./ExtUtils::MakeMaker.html#ABSTRACT_FROM">#</a>ABSTRACT_FROM</dt>
<dd>

<p>Name of the file that contains the package description. MakeMaker looks for a line in the POD matching /^($package\s-\s)(.*)/. This is typically the first line in the &quot;=head1 NAME&quot; section. $2 becomes the abstract.</p>

</dd>
<dt id="AUTHOR"><a class="permalink" href="./ExtUtils::MakeMaker.html#AUTHOR">#</a>AUTHOR</dt>
<dd>

<p>Array of strings containing name (and email address) of package author(s). Is used in CPAN Meta files (META.yml or META.json) and PPD (Perl Package Description) files for PPM (Perl Package Manager).</p>

</dd>
<dt id="BINARY_LOCATION"><a class="permalink" href="./ExtUtils::MakeMaker.html#BINARY_LOCATION">#</a>BINARY_LOCATION</dt>
<dd>

<p>Used when creating PPD files for binary packages. It can be set to a full or relative path or URL to the binary archive for a particular architecture. For example:</p>

<pre><code class="plaintext">perl Makefile.PL BINARY_LOCATION=x86/Agent.tar.gz</code></pre>

<p>builds a PPD package that references a binary of the <code>Agent</code> package, located in the <code>x86</code> directory relative to the PPD itself.</p>

</dd>
<dt id="BUILD_REQUIRES"><a class="permalink" href="./ExtUtils::MakeMaker.html#BUILD_REQUIRES">#</a>BUILD_REQUIRES</dt>
<dd>

<p>Available in version 6.55_03 and above.</p>

<p>A hash of modules that are needed to build your module but not run it.</p>

<p>This will go into the <code>build_requires</code> field of your <i>META.yml</i> and the <code>build</code> of the <code>prereqs</code> field of your <i>META.json</i>.</p>

<p>Defaults to <code>{ &quot;ExtUtils::MakeMaker&quot; =&gt; 0 }</code> if this attribute is not specified.</p>

<p>The format is the same as PREREQ_PM.</p>

</dd>
<dt id="C"><a class="permalink" href="./ExtUtils::MakeMaker.html#C">#</a>C</dt>
<dd>

<p>Ref to array of *.c file names. Initialised from a directory scan and the values portion of the XS attribute hash. This is not currently used by MakeMaker but may be handy in Makefile.PLs.</p>

</dd>
<dt id="CCFLAGS"><a class="permalink" href="./ExtUtils::MakeMaker.html#CCFLAGS">#</a>CCFLAGS</dt>
<dd>

<p>String that will be included in the compiler call command line between the arguments INC and OPTIMIZE.</p>

</dd>
<dt id="CONFIG"><a class="permalink" href="./ExtUtils::MakeMaker.html#CONFIG">#</a>CONFIG</dt>
<dd>

<p>Arrayref. E.g. [qw(archname manext)] defines ARCHNAME &amp; MANEXT from config.sh. MakeMaker will add to CONFIG the following values anyway: ar cc cccdlflags ccdlflags dlext dlsrc ld lddlflags ldflags libc lib_ext obj_ext ranlib sitelibexp sitearchexp so</p>

</dd>
<dt id="CONFIGURE"><a class="permalink" href="./ExtUtils::MakeMaker.html#CONFIGURE">#</a>CONFIGURE</dt>
<dd>

<p>CODE reference. The subroutine should return a hash reference. The hash may contain further attributes, e.g. {LIBS =&gt; ...}, that have to be determined by some evaluation method.</p>

</dd>
<dt id="CONFIGURE_REQUIRES"><a class="permalink" href="./ExtUtils::MakeMaker.html#CONFIGURE_REQUIRES">#</a>CONFIGURE_REQUIRES</dt>
<dd>

<p>Available in version 6.52 and above.</p>

<p>A hash of modules that are required to run Makefile.PL itself, but not to run your distribution.</p>

<p>This will go into the <code>configure_requires</code> field of your <i>META.yml</i> and the <code>configure</code> of the <code>prereqs</code> field of your <i>META.json</i>.</p>

<p>Defaults to <code>{ &quot;ExtUtils::MakeMaker&quot; =&gt; 0 }</code> if this attribute is not specified.</p>

<p>The format is the same as PREREQ_PM.</p>

</dd>
<dt id="DEFINE"><a class="permalink" href="./ExtUtils::MakeMaker.html#DEFINE">#</a>DEFINE</dt>
<dd>

<p>Something like <code>&quot;-DHAVE_UNISTD_H&quot;</code></p>

</dd>
<dt id="DESTDIR"><a class="permalink" href="./ExtUtils::MakeMaker.html#DESTDIR">#</a>DESTDIR</dt>
<dd>

<p>This is the root directory into which the code will be installed. It <i>prepends itself to the normal prefix</i>. For example, if your code would normally go into <i>/usr/local/lib/perl</i> you could set DESTDIR=~/tmp/ and installation would go into <i>~/tmp/usr/local/lib/perl</i>.</p>

<p>This is primarily of use for people who repackage Perl modules.</p>

<p>NOTE: Due to the nature of make, it is important that you put the trailing slash on your DESTDIR. <i>~/tmp/</i> not <i>~/tmp</i>.</p>

</dd>
<dt id="DIR"><a class="permalink" href="./ExtUtils::MakeMaker.html#DIR">#</a>DIR</dt>
<dd>

<p>Ref to array of subdirectories containing Makefile.PLs e.g. [&#39;sdbm&#39;] in ext/SDBM_File</p>

</dd>
<dt id="DISTNAME"><a class="permalink" href="./ExtUtils::MakeMaker.html#DISTNAME">#</a>DISTNAME</dt>
<dd>

<p>A safe filename for the package.</p>

<p>Defaults to NAME below but with :: replaced with -.</p>

<p>For example, Foo::Bar becomes Foo-Bar.</p>

</dd>
<dt id="DISTVNAME"><a class="permalink" href="./ExtUtils::MakeMaker.html#DISTVNAME">#</a>DISTVNAME</dt>
<dd>

<p>Your name for distributing the package with the version number included. This is used by &#39;make dist&#39; to name the resulting archive file.</p>

<p>Defaults to DISTNAME-VERSION.</p>

<p>For example, version 1.04 of Foo::Bar becomes Foo-Bar-1.04.</p>

<p>On some OS&#39;s where . has special meaning VERSION_SYM may be used in place of VERSION.</p>

</dd>
<dt id="DLEXT"><a class="permalink" href="./ExtUtils::MakeMaker.html#DLEXT">#</a>DLEXT</dt>
<dd>

<p>Specifies the extension of the module&#39;s loadable object. For example:</p>

<pre><code>DLEXT =&gt; &#39;unusual_ext&#39;, # Default value is $Config{so}</code></pre>

<p>NOTE: When using this option to alter the extension of a module&#39;s loadable object, it is also necessary that the module&#39;s pm file specifies the same change:</p>

<pre><code>local $DynaLoader::dl_dlext = &#39;unusual_ext&#39;;</code></pre>

</dd>
<dt id="DL_FUNCS"><a class="permalink" href="./ExtUtils::MakeMaker.html#DL_FUNCS">#</a>DL_FUNCS</dt>
<dd>

<p>Hashref of symbol names for routines to be made available as universal symbols. Each key/value pair consists of the package name and an array of routine names in that package. Used only under AIX, OS/2, VMS and Win32 at present. The routine names supplied will be expanded in the same way as XSUB names are expanded by the XS() macro. Defaults to</p>

<pre><code class="plaintext">{&quot;$(NAME)&quot; =&gt; [&quot;boot_$(NAME)&quot; ] }</code></pre>

<p>e.g.</p>

<pre><code class="plaintext">{&quot;RPC&quot; =&gt; [qw( boot_rpcb rpcb_gettime getnetconfigent )],
 &quot;NetconfigPtr&quot; =&gt; [ &#39;DESTROY&#39;] }</code></pre>

<p>Please see the <a href="./ExtUtils::Mksymlists.html">ExtUtils::Mksymlists</a> documentation for more information about the DL_FUNCS, DL_VARS and FUNCLIST attributes.</p>

</dd>
<dt id="DL_VARS"><a class="permalink" href="./ExtUtils::MakeMaker.html#DL_VARS">#</a>DL_VARS</dt>
<dd>

<p>Array of symbol names for variables to be made available as universal symbols. Used only under AIX, OS/2, VMS and Win32 at present. Defaults to []. (e.g. [ qw(Foo_version Foo_numstreams Foo_tree ) ])</p>

</dd>
<dt id="EXCLUDE_EXT"><a class="permalink" href="./ExtUtils::MakeMaker.html#EXCLUDE_EXT">#</a>EXCLUDE_EXT</dt>
<dd>

<p>Array of extension names to exclude when doing a static build. This is ignored if INCLUDE_EXT is present. Consult INCLUDE_EXT for more details. (e.g. [ qw( Socket POSIX ) ] )</p>

<p>This attribute may be most useful when specified as a string on the command line: perl Makefile.PL EXCLUDE_EXT=&#39;Socket Safe&#39;</p>

</dd>
<dt id="EXE_FILES"><a class="permalink" href="./ExtUtils::MakeMaker.html#EXE_FILES">#</a>EXE_FILES</dt>
<dd>

<p>Ref to array of executable files. The files will be copied to the INST_SCRIPT directory. Make realclean will delete them from there again.</p>

<p>If your executables start with something like #!perl or #!/usr/bin/perl MakeMaker will change this to the path of the perl &#39;Makefile.PL&#39; was invoked with so the programs will be sure to run properly even if perl is not in /usr/bin/perl.</p>

</dd>
<dt id="FIRST_MAKEFILE"><a class="permalink" href="./ExtUtils::MakeMaker.html#FIRST_MAKEFILE">#</a>FIRST_MAKEFILE</dt>
<dd>

<p>The name of the Makefile to be produced. This is used for the second Makefile that will be produced for the MAP_TARGET.</p>

<p>Defaults to &#39;Makefile&#39; or &#39;Descrip.MMS&#39; on VMS.</p>

<p>(Note: we couldn&#39;t use MAKEFILE because dmake uses this for something else).</p>

</dd>
<dt id="FULLPERL"><a class="permalink" href="./ExtUtils::MakeMaker.html#FULLPERL">#</a>FULLPERL</dt>
<dd>

<p>Perl binary able to run this extension, load XS modules, etc...</p>

</dd>
<dt id="FULLPERLRUN"><a class="permalink" href="./ExtUtils::MakeMaker.html#FULLPERLRUN">#</a>FULLPERLRUN</dt>
<dd>

<p>Like PERLRUN, except it uses FULLPERL.</p>

</dd>
<dt id="FULLPERLRUNINST"><a class="permalink" href="./ExtUtils::MakeMaker.html#FULLPERLRUNINST">#</a>FULLPERLRUNINST</dt>
<dd>

<p>Like PERLRUNINST, except it uses FULLPERL.</p>

</dd>
<dt id="FUNCLIST"><a class="permalink" href="./ExtUtils::MakeMaker.html#FUNCLIST">#</a>FUNCLIST</dt>
<dd>

<p>This provides an alternate means to specify function names to be exported from the extension. Its value is a reference to an array of function names to be exported by the extension. These names are passed through unaltered to the linker options file.</p>

</dd>
<dt id="H"><a class="permalink" href="./ExtUtils::MakeMaker.html#H">#</a>H</dt>
<dd>

<p>Ref to array of *.h file names. Similar to C.</p>

</dd>
<dt id="IMPORTS"><a class="permalink" href="./ExtUtils::MakeMaker.html#IMPORTS">#</a>IMPORTS</dt>
<dd>

<p>This attribute is used to specify names to be imported into the extension. Takes a hash ref.</p>

<p>It is only used on OS/2 and Win32.</p>

</dd>
<dt id="INC"><a class="permalink" href="./ExtUtils::MakeMaker.html#INC">#</a>INC</dt>
<dd>

<p>Include file dirs eg: <code>&quot;-I/usr/5include -I/path/to/inc&quot;</code></p>

</dd>
<dt id="INCLUDE_EXT"><a class="permalink" href="./ExtUtils::MakeMaker.html#INCLUDE_EXT">#</a>INCLUDE_EXT</dt>
<dd>

<p>Array of extension names to be included when doing a static build. MakeMaker will normally build with all of the installed extensions when doing a static build, and that is usually the desired behavior. If INCLUDE_EXT is present then MakeMaker will build only with those extensions which are explicitly mentioned. (e.g. [ qw( Socket POSIX ) ])</p>

<p>It is not necessary to mention DynaLoader or the current extension when filling in INCLUDE_EXT. If the INCLUDE_EXT is mentioned but is empty then only DynaLoader and the current extension will be included in the build.</p>

<p>This attribute may be most useful when specified as a string on the command line: perl Makefile.PL INCLUDE_EXT=&#39;POSIX Socket Devel::Peek&#39;</p>

</dd>
<dt id="INSTALLARCHLIB"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLARCHLIB">#</a>INSTALLARCHLIB</dt>
<dd>

<p>Used by &#39;make install&#39;, which copies files from INST_ARCHLIB to this directory if INSTALLDIRS is set to perl.</p>

</dd>
<dt id="INSTALLBIN"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLBIN">#</a>INSTALLBIN</dt>
<dd>

<p>Directory to install binary files (e.g. tkperl) into if INSTALLDIRS=perl.</p>

</dd>
<dt id="INSTALLDIRS"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLDIRS">#</a>INSTALLDIRS</dt>
<dd>

<p>Determines which of the sets of installation directories to choose: perl, site or vendor. Defaults to site.</p>

</dd>
<dt id="INSTALLMAN1DIR"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLMAN1DIR">#</a>INSTALLMAN1DIR</dt>
<dd>

</dd>
<dt id="INSTALLMAN3DIR"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLMAN3DIR">#</a>INSTALLMAN3DIR</dt>
<dd>

<p>These directories get the man pages at &#39;make install&#39; time if INSTALLDIRS=perl. Defaults to $Config{installman*dir}.</p>

<p>If set to &#39;none&#39;, no man pages will be installed.</p>

</dd>
<dt id="INSTALLPRIVLIB"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLPRIVLIB">#</a>INSTALLPRIVLIB</dt>
<dd>

<p>Used by &#39;make install&#39;, which copies files from INST_LIB to this directory if INSTALLDIRS is set to perl.</p>

<p>Defaults to $Config{installprivlib}.</p>

</dd>
<dt id="INSTALLSCRIPT"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLSCRIPT">#</a>INSTALLSCRIPT</dt>
<dd>

<p>Available in version 6.30_02 and above.</p>

<p>Used by &#39;make install&#39; which copies files from INST_SCRIPT to this directory if INSTALLDIRS=perl.</p>

</dd>
<dt id="INSTALLSITEARCH"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLSITEARCH">#</a>INSTALLSITEARCH</dt>
<dd>

<p>Used by &#39;make install&#39;, which copies files from INST_ARCHLIB to this directory if INSTALLDIRS is set to site (default).</p>

</dd>
<dt id="INSTALLSITEBIN"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLSITEBIN">#</a>INSTALLSITEBIN</dt>
<dd>

<p>Used by &#39;make install&#39;, which copies files from INST_BIN to this directory if INSTALLDIRS is set to site (default).</p>

</dd>
<dt id="INSTALLSITELIB"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLSITELIB">#</a>INSTALLSITELIB</dt>
<dd>

<p>Used by &#39;make install&#39;, which copies files from INST_LIB to this directory if INSTALLDIRS is set to site (default).</p>

</dd>
<dt id="INSTALLSITEMAN1DIR"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLSITEMAN1DIR">#</a>INSTALLSITEMAN1DIR</dt>
<dd>

</dd>
<dt id="INSTALLSITEMAN3DIR"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLSITEMAN3DIR">#</a>INSTALLSITEMAN3DIR</dt>
<dd>

<p>These directories get the man pages at &#39;make install&#39; time if INSTALLDIRS=site (default). Defaults to $(SITEPREFIX)/man/man$(MAN*EXT).</p>

<p>If set to &#39;none&#39;, no man pages will be installed.</p>

</dd>
<dt id="INSTALLSITESCRIPT"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLSITESCRIPT">#</a>INSTALLSITESCRIPT</dt>
<dd>

<p>Used by &#39;make install&#39; which copies files from INST_SCRIPT to this directory if INSTALLDIRS is set to site (default).</p>

</dd>
<dt id="INSTALLVENDORARCH"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLVENDORARCH">#</a>INSTALLVENDORARCH</dt>
<dd>

<p>Used by &#39;make install&#39;, which copies files from INST_ARCHLIB to this directory if INSTALLDIRS is set to vendor. Note that if you do not set this, the value of INSTALLVENDORLIB will be used, which is probably not what you want.</p>

</dd>
<dt id="INSTALLVENDORBIN"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLVENDORBIN">#</a>INSTALLVENDORBIN</dt>
<dd>

<p>Used by &#39;make install&#39;, which copies files from INST_BIN to this directory if INSTALLDIRS is set to vendor.</p>

</dd>
<dt id="INSTALLVENDORLIB"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLVENDORLIB">#</a>INSTALLVENDORLIB</dt>
<dd>

<p>Used by &#39;make install&#39;, which copies files from INST_LIB to this directory if INSTALLDIRS is set to vendor.</p>

</dd>
<dt id="INSTALLVENDORMAN1DIR"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLVENDORMAN1DIR">#</a>INSTALLVENDORMAN1DIR</dt>
<dd>

</dd>
<dt id="INSTALLVENDORMAN3DIR"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLVENDORMAN3DIR">#</a>INSTALLVENDORMAN3DIR</dt>
<dd>

<p>These directories get the man pages at &#39;make install&#39; time if INSTALLDIRS=vendor. Defaults to $(VENDORPREFIX)/man/man$(MAN*EXT).</p>

<p>If set to &#39;none&#39;, no man pages will be installed.</p>

</dd>
<dt id="INSTALLVENDORSCRIPT"><a class="permalink" href="./ExtUtils::MakeMaker.html#INSTALLVENDORSCRIPT">#</a>INSTALLVENDORSCRIPT</dt>
<dd>

<p>Available in version 6.30_02 and above.</p>

<p>Used by &#39;make install&#39; which copies files from INST_SCRIPT to this directory if INSTALLDIRS is set to vendor.</p>

</dd>
<dt id="INST_ARCHLIB"><a class="permalink" href="./ExtUtils::MakeMaker.html#INST_ARCHLIB">#</a>INST_ARCHLIB</dt>
<dd>

<p>Same as INST_LIB for architecture dependent files.</p>

</dd>
<dt id="INST_BIN"><a class="permalink" href="./ExtUtils::MakeMaker.html#INST_BIN">#</a>INST_BIN</dt>
<dd>

<p>Directory to put real binary files during &#39;make&#39;. These will be copied to INSTALLBIN during &#39;make install&#39;</p>

</dd>
<dt id="INST_LIB"><a class="permalink" href="./ExtUtils::MakeMaker.html#INST_LIB">#</a>INST_LIB</dt>
<dd>

<p>Directory where we put library files of this extension while building it.</p>

</dd>
<dt id="INST_MAN1DIR"><a class="permalink" href="./ExtUtils::MakeMaker.html#INST_MAN1DIR">#</a>INST_MAN1DIR</dt>
<dd>

<p>Directory to hold the man pages at &#39;make&#39; time</p>

</dd>
<dt id="INST_MAN3DIR"><a class="permalink" href="./ExtUtils::MakeMaker.html#INST_MAN3DIR">#</a>INST_MAN3DIR</dt>
<dd>

<p>Directory to hold the man pages at &#39;make&#39; time</p>

</dd>
<dt id="INST_SCRIPT"><a class="permalink" href="./ExtUtils::MakeMaker.html#INST_SCRIPT">#</a>INST_SCRIPT</dt>
<dd>

<p>Directory where executable files should be installed during &#39;make&#39;. Defaults to &quot;./blib/script&quot;, just to have a dummy location during testing. make install will copy the files in INST_SCRIPT to INSTALLSCRIPT.</p>

</dd>
<dt id="LD"><a class="permalink" href="./ExtUtils::MakeMaker.html#LD">#</a>LD</dt>
<dd>

<p>Program to be used to link libraries for dynamic loading.</p>

<p>Defaults to $Config{ld}.</p>

</dd>
<dt id="LDDLFLAGS"><a class="permalink" href="./ExtUtils::MakeMaker.html#LDDLFLAGS">#</a>LDDLFLAGS</dt>
<dd>

<p>Any special flags that might need to be passed to ld to create a shared library suitable for dynamic loading. It is up to the makefile to use it. (See <a href="Config.html#lddlflags">&quot;lddlflags&quot; in Config</a>)</p>

<p>Defaults to $Config{lddlflags}.</p>

</dd>
<dt id="LDFROM"><a class="permalink" href="./ExtUtils::MakeMaker.html#LDFROM">#</a>LDFROM</dt>
<dd>

<p>Defaults to &quot;$(OBJECT)&quot; and is used in the ld command to specify what files to link/load from (also see dynamic_lib below for how to specify ld flags)</p>

</dd>
<dt id="LIB"><a class="permalink" href="./ExtUtils::MakeMaker.html#LIB">#</a>LIB</dt>
<dd>

<p>LIB should only be set at <code>perl Makefile.PL</code> time but is allowed as a MakeMaker argument. It has the effect of setting both INSTALLPRIVLIB and INSTALLSITELIB to that value regardless any explicit setting of those arguments (or of PREFIX). INSTALLARCHLIB and INSTALLSITEARCH are set to the corresponding architecture subdirectory.</p>

</dd>
<dt id="LIBPERL_A"><a class="permalink" href="./ExtUtils::MakeMaker.html#LIBPERL_A">#</a>LIBPERL_A</dt>
<dd>

<p>The filename of the perllibrary that will be used together with this extension. Defaults to libperl.a.</p>

</dd>
<dt id="LIBS"><a class="permalink" href="./ExtUtils::MakeMaker.html#LIBS">#</a>LIBS</dt>
<dd>

<p>An anonymous array of alternative library specifications to be searched for (in order) until at least one library is found. E.g.</p>

<pre><code class="plaintext">&#39;LIBS&#39; =&gt; [&quot;-lgdbm&quot;, &quot;-ldbm -lfoo&quot;, &quot;-L/path -ldbm.nfs&quot;]</code></pre>

<p>Mind, that any element of the array contains a complete set of arguments for the ld command. So do not specify</p>

<pre><code class="plaintext">&#39;LIBS&#39; =&gt; [&quot;-ltcl&quot;, &quot;-ltk&quot;, &quot;-lX11&quot;]</code></pre>

<p>See ODBM_File/Makefile.PL for an example, where an array is needed. If you specify a scalar as in</p>

<pre><code class="plaintext">&#39;LIBS&#39; =&gt; &quot;-ltcl -ltk -lX11&quot;</code></pre>

<p>MakeMaker will turn it into an array with one element.</p>

</dd>
<dt id="LICENSE"><a class="permalink" href="./ExtUtils::MakeMaker.html#LICENSE">#</a>LICENSE</dt>
<dd>

<p>Available in version 6.31 and above.</p>

<p>The licensing terms of your distribution. Generally it&#39;s &quot;perl_5&quot; for the same license as Perl itself.</p>

<p>See <a href="./CPAN::Meta::Spec.html">CPAN::Meta::Spec</a> for the list of options.</p>

<p>Defaults to &quot;unknown&quot;.</p>

</dd>
<dt id="LINKTYPE"><a class="permalink" href="./ExtUtils::MakeMaker.html#LINKTYPE">#</a>LINKTYPE</dt>
<dd>

<p>&#39;static&#39; or &#39;dynamic&#39; (default unless usedl=undef in config.sh). Should only be used to force static linking (also see linkext below).</p>

</dd>
<dt id="MAGICXS"><a class="permalink" href="./ExtUtils::MakeMaker.html#MAGICXS">#</a>MAGICXS</dt>
<dd>

<p>Available in version 6.8305 and above.</p>

<p>When this is set to <code>1</code>, <code>OBJECT</code> will be automagically derived from <code>O_FILES</code>.</p>

</dd>
<dt id="MAKE"><a class="permalink" href="./ExtUtils::MakeMaker.html#MAKE">#</a>MAKE</dt>
<dd>

<p>Available in version 6.30_01 and above.</p>

<p>Variant of make you intend to run the generated Makefile with. This parameter lets Makefile.PL know what make quirks to account for when generating the Makefile.</p>

<p>MakeMaker also honors the MAKE environment variable. This parameter takes precedence.</p>

<p>Currently the only significant values are &#39;dmake&#39; and &#39;nmake&#39; for Windows users, instructing MakeMaker to generate a Makefile in the flavour of DMake (&quot;Dennis Vadura&#39;s Make&quot;) or Microsoft NMake respectively.</p>

<p>Defaults to $Config{make}, which may go looking for a Make program in your environment.</p>

<p>How are you supposed to know what flavour of Make a Makefile has been generated for if you didn&#39;t specify a value explicitly? Search the generated Makefile for the definition of the MAKE variable, which is used to recursively invoke the Make utility. That will tell you what Make you&#39;re supposed to invoke the Makefile with.</p>

</dd>
<dt id="MAKEAPERL"><a class="permalink" href="./ExtUtils::MakeMaker.html#MAKEAPERL">#</a>MAKEAPERL</dt>
<dd>

<p>Boolean which tells MakeMaker that it should include the rules to make a perl. This is handled automatically as a switch by MakeMaker. The user normally does not need it.</p>

</dd>
<dt id="MAKEFILE_OLD"><a class="permalink" href="./ExtUtils::MakeMaker.html#MAKEFILE_OLD">#</a>MAKEFILE_OLD</dt>
<dd>

<p>When &#39;make clean&#39; or similar is run, the $(FIRST_MAKEFILE) will be backed up at this location.</p>

<p>Defaults to $(FIRST_MAKEFILE).old or $(FIRST_MAKEFILE)_old on VMS.</p>

</dd>
<dt id="MAN1PODS"><a class="permalink" href="./ExtUtils::MakeMaker.html#MAN1PODS">#</a>MAN1PODS</dt>
<dd>

<p>Hashref of pod-containing files. MakeMaker will default this to all EXE_FILES files that include POD directives. The files listed here will be converted to man pages and installed as was requested at Configure time.</p>

<p>This hash should map POD files (or scripts containing POD) to the man file names under the <code>blib/man1/</code> directory, as in the following example:</p>

<pre><code>MAN1PODS            =&gt; {
  &#39;doc/command.pod&#39;    =&gt; &#39;blib/man1/command.1&#39;,
  &#39;scripts/script.pl&#39;  =&gt; &#39;blib/man1/script.1&#39;,
}</code></pre>

</dd>
<dt id="MAN3PODS"><a class="permalink" href="./ExtUtils::MakeMaker.html#MAN3PODS">#</a>MAN3PODS</dt>
<dd>

<p>Hashref that assigns to *.pm and *.pod files the files into which the manpages are to be written. MakeMaker parses all *.pod and *.pm files for POD directives. Files that contain POD will be the default keys of the MAN3PODS hashref. These will then be converted to man pages during <code>make</code> and will be installed during <code>make install</code>.</p>

<p>Example similar to MAN1PODS.</p>

</dd>
<dt id="MAP_TARGET"><a class="permalink" href="./ExtUtils::MakeMaker.html#MAP_TARGET">#</a>MAP_TARGET</dt>
<dd>

<p>If it is intended that a new perl binary be produced, this variable may hold a name for that binary. Defaults to perl</p>

</dd>
<dt id="META_ADD"><a class="permalink" href="./ExtUtils::MakeMaker.html#META_ADD">#</a>META_ADD</dt>
<dd>

</dd>
<dt id="META_MERGE"><a class="permalink" href="./ExtUtils::MakeMaker.html#META_MERGE">#</a>META_MERGE</dt>
<dd>

<p>Available in version 6.46 and above.</p>

<p>A hashref of items to add to the CPAN Meta file (<i>META.yml</i> or <i>META.json</i>).</p>

<p>They differ in how they behave if they have the same key as the default metadata. META_ADD will override the default value with its own. META_MERGE will merge its value with the default.</p>

<p>Unless you want to override the defaults, prefer META_MERGE so as to get the advantage of any future defaults.</p>

<p>Where prereqs are concerned, if META_MERGE is used, prerequisites are merged with their counterpart <code>WriteMakefile()</code> argument (PREREQ_PM is merged into {prereqs}{runtime}{requires}, BUILD_REQUIRES into <code>{prereqs}{build}{requires}</code>, CONFIGURE_REQUIRES into <code>{prereqs}{configure}{requires}</code>, and TEST_REQUIRES into <code>{prereqs}{test}{requires})</code>. When prereqs are specified with META_ADD, the only prerequisites added to the file come from the metadata, not <code>WriteMakefile()</code> arguments.</p>

<p>Note that these configuration options are only used for generating <i>META.yml</i> and <i>META.json</i> -- they are NOT used for <i>MYMETA.yml</i> and <i>MYMETA.json</i>. Therefore data in these fields should NOT be used for dynamic (user-side) configuration.</p>

<p>By default CPAN Meta specification <code>1.4</code> is used. In order to use CPAN Meta specification <code>2.0</code>, indicate with <code>meta-spec</code> the version you want to use.</p>

<pre><code>META_MERGE        =&gt; {

  &quot;meta-spec&quot; =&gt; { version =&gt; 2 },

  resources =&gt; {

    repository =&gt; {
        type =&gt; &#39;git&#39;,
        url =&gt; &#39;git://github.com/Perl-Toolchain-Gang/ExtUtils-MakeMaker.git&#39;,
        web =&gt; &#39;https://github.com/Perl-Toolchain-Gang/ExtUtils-MakeMaker&#39;,
    },

  },

},</code></pre>

</dd>
<dt id="MIN_PERL_VERSION"><a class="permalink" href="./ExtUtils::MakeMaker.html#MIN_PERL_VERSION">#</a>MIN_PERL_VERSION</dt>
<dd>

<p>Available in version 6.48 and above.</p>

<p>The minimum required version of Perl for this distribution.</p>

<p>Either the 5.006001 or the 5.6.1 format is acceptable.</p>

</dd>
<dt id="MYEXTLIB"><a class="permalink" href="./ExtUtils::MakeMaker.html#MYEXTLIB">#</a>MYEXTLIB</dt>
<dd>

<p>If the extension links to a library that it builds, set this to the name of the library (see SDBM_File)</p>

</dd>
<dt id="NAME1"><a class="permalink" href="./ExtUtils::MakeMaker.html#NAME1">#</a>NAME</dt>
<dd>

<p>The package representing the distribution. For example, <code>Test::More</code> or <code>ExtUtils::MakeMaker</code>. It will be used to derive information about the distribution such as the <a href="./ExtUtils::MakeMaker.html#DISTNAME">&quot;DISTNAME&quot;</a>, installation locations within the Perl library and where XS files will be looked for by default (see <a href="./ExtUtils::MakeMaker.html#XS">&quot;XS&quot;</a>).</p>

<p><code>NAME</code> <i>must</i> be a valid Perl package name and it <i>must</i> have an associated <code>.pm</code> file. For example, <code>Foo::Bar</code> is a valid <code>NAME</code> and there must exist <i>Foo/Bar.pm</i>. Any XS code should be in <i>Bar.xs</i> unless stated otherwise.</p>

<p>Your distribution <b>must</b> have a <code>NAME</code>.</p>

</dd>
<dt id="NEEDS_LINKING"><a class="permalink" href="./ExtUtils::MakeMaker.html#NEEDS_LINKING">#</a>NEEDS_LINKING</dt>
<dd>

<p>MakeMaker will figure out if an extension contains linkable code anywhere down the directory tree, and will set this variable accordingly, but you can speed it up a very little bit if you define this boolean variable yourself.</p>

</dd>
<dt id="NOECHO"><a class="permalink" href="./ExtUtils::MakeMaker.html#NOECHO">#</a>NOECHO</dt>
<dd>

<p>Command so make does not print the literal commands it&#39;s running.</p>

<p>By setting it to an empty string you can generate a Makefile that prints all commands. Mainly used in debugging MakeMaker itself.</p>

<p>Defaults to <code>@</code>.</p>

</dd>
<dt id="NORECURS"><a class="permalink" href="./ExtUtils::MakeMaker.html#NORECURS">#</a>NORECURS</dt>
<dd>

<p>Boolean. Attribute to inhibit descending into subdirectories.</p>

</dd>
<dt id="NO_META"><a class="permalink" href="./ExtUtils::MakeMaker.html#NO_META">#</a>NO_META</dt>
<dd>

<p>When true, suppresses the generation and addition to the MANIFEST of the META.yml and META.json module meta-data files during &#39;make distdir&#39;.</p>

<p>Defaults to false.</p>

</dd>
<dt id="NO_MYMETA"><a class="permalink" href="./ExtUtils::MakeMaker.html#NO_MYMETA">#</a>NO_MYMETA</dt>
<dd>

<p>Available in version 6.57_02 and above.</p>

<p>When true, suppresses the generation of MYMETA.yml and MYMETA.json module meta-data files during &#39;perl Makefile.PL&#39;.</p>

<p>Defaults to false.</p>

</dd>
<dt id="NO_PACKLIST"><a class="permalink" href="./ExtUtils::MakeMaker.html#NO_PACKLIST">#</a>NO_PACKLIST</dt>
<dd>

<p>Available in version 6.7501 and above.</p>

<p>When true, suppresses the writing of <code>packlist</code> files for installs.</p>

<p>Defaults to false.</p>

</dd>
<dt id="NO_PERLLOCAL"><a class="permalink" href="./ExtUtils::MakeMaker.html#NO_PERLLOCAL">#</a>NO_PERLLOCAL</dt>
<dd>

<p>Available in version 6.7501 and above.</p>

<p>When true, suppresses the appending of installations to <code>perllocal</code>.</p>

<p>Defaults to false.</p>

</dd>
<dt id="NO_VC"><a class="permalink" href="./ExtUtils::MakeMaker.html#NO_VC">#</a>NO_VC</dt>
<dd>

<p>In general, any generated Makefile checks for the current version of MakeMaker and the version the Makefile was built under. If NO_VC is set, the version check is neglected. Do not write this into your Makefile.PL, use it interactively instead.</p>

</dd>
<dt id="OBJECT"><a class="permalink" href="./ExtUtils::MakeMaker.html#OBJECT">#</a>OBJECT</dt>
<dd>

<p>List of object files, defaults to &#39;$(BASEEXT)$(OBJ_EXT)&#39;, but can be a long string or an array containing all object files, e.g. &quot;tkpBind.o tkpButton.o tkpCanvas.o&quot; or [&quot;tkpBind.o&quot;, &quot;tkpButton.o&quot;, &quot;tkpCanvas.o&quot;]</p>

<p>(Where BASEEXT is the last component of NAME, and OBJ_EXT is $Config{obj_ext}.)</p>

</dd>
<dt id="OPTIMIZE"><a class="permalink" href="./ExtUtils::MakeMaker.html#OPTIMIZE">#</a>OPTIMIZE</dt>
<dd>

<p>Defaults to <code>-O</code>. Set it to <code>-g</code> to turn debugging on. The flag is passed to subdirectory makes.</p>

</dd>
<dt id="PERL"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERL">#</a>PERL</dt>
<dd>

<p>Perl binary for tasks that can be done by miniperl. If it contains spaces or other shell metacharacters, it needs to be quoted in a way that protects them, since this value is intended to be inserted in a shell command line in the Makefile. E.g.:</p>

<pre><code class="plaintext"># Perl executable lives in &quot;C:/Program Files/Perl/bin&quot;
# Normally you don&#39;t need to set this yourself!
$ perl Makefile.PL PERL=&#39;&quot;C:/Program Files/Perl/bin/perl.exe&quot; -w&#39;</code></pre>

</dd>
<dt id="PERL_CORE"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERL_CORE">#</a>PERL_CORE</dt>
<dd>

<p>Set only when MakeMaker is building the extensions of the Perl core distribution.</p>

</dd>
<dt id="PERLMAINCC"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERLMAINCC">#</a>PERLMAINCC</dt>
<dd>

<p>The call to the program that is able to compile perlmain.c. Defaults to $(CC).</p>

</dd>
<dt id="PERL_ARCHLIB"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERL_ARCHLIB">#</a>PERL_ARCHLIB</dt>
<dd>

<p>Same as for PERL_LIB, but for architecture dependent files.</p>

<p>Used only when MakeMaker is building the extensions of the Perl core distribution (because normally $(PERL_ARCHLIB) is automatically in @INC, and adding it would get in the way of PERL5LIB).</p>

</dd>
<dt id="PERL_LIB"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERL_LIB">#</a>PERL_LIB</dt>
<dd>

<p>Directory containing the Perl library to use.</p>

<p>Used only when MakeMaker is building the extensions of the Perl core distribution (because normally $(PERL_LIB) is automatically in @INC, and adding it would get in the way of PERL5LIB).</p>

</dd>
<dt id="PERL_MALLOC_OK"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERL_MALLOC_OK">#</a>PERL_MALLOC_OK</dt>
<dd>

<p>defaults to 0. Should be set to TRUE if the extension can work with the memory allocation routines substituted by the Perl malloc() subsystem. This should be applicable to most extensions with exceptions of those</p>

<ul>

<li><p>with bugs in memory allocations which are caught by Perl&#39;s malloc();</p>

</li>
<li><p>which interact with the memory allocator in other ways than via malloc(), realloc(), free(), calloc(), sbrk() and brk();</p>

</li>
<li><p>which rely on special alignment which is not provided by Perl&#39;s malloc().</p>

</li>
</ul>

<p><b>NOTE.</b> Neglecting to set this flag in <i>any one</i> of the loaded extension nullifies many advantages of Perl&#39;s malloc(), such as better usage of system resources, error detection, memory usage reporting, catchable failure of memory allocations, etc.</p>

</dd>
<dt id="PERLPREFIX"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERLPREFIX">#</a>PERLPREFIX</dt>
<dd>

<p>Directory under which core modules are to be installed.</p>

<p>Defaults to $Config{installprefixexp}, falling back to $Config{installprefix}, $Config{prefixexp} or $Config{prefix} should $Config{installprefixexp} not exist.</p>

<p>Overridden by PREFIX.</p>

</dd>
<dt id="PERLRUN"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERLRUN">#</a>PERLRUN</dt>
<dd>

<p>Use this instead of $(PERL) when you wish to run perl. It will set up extra necessary flags for you.</p>

</dd>
<dt id="PERLRUNINST"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERLRUNINST">#</a>PERLRUNINST</dt>
<dd>

<p>Use this instead of $(PERL) when you wish to run perl to work with modules. It will add things like -I$(INST_ARCH) and other necessary flags so perl can see the modules you&#39;re about to install.</p>

</dd>
<dt id="PERL_SRC"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERL_SRC">#</a>PERL_SRC</dt>
<dd>

<p>Directory containing the Perl source code (use of this should be avoided, it may be undefined)</p>

</dd>
<dt id="PERM_DIR"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERM_DIR">#</a>PERM_DIR</dt>
<dd>

<p>Available in version 6.51_01 and above.</p>

<p>Desired permission for directories. Defaults to <code>755</code>.</p>

</dd>
<dt id="PERM_RW"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERM_RW">#</a>PERM_RW</dt>
<dd>

<p>Desired permission for read/writable files. Defaults to <code>644</code>.</p>

</dd>
<dt id="PERM_RWX"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERM_RWX">#</a>PERM_RWX</dt>
<dd>

<p>Desired permission for executable files. Defaults to <code>755</code>.</p>

</dd>
<dt id="PL_FILES"><a class="permalink" href="./ExtUtils::MakeMaker.html#PL_FILES">#</a>PL_FILES</dt>
<dd>

<p>MakeMaker can run programs to generate files for you at build time. By default any file named *.PL (except Makefile.PL and Build.PL) in the top level directory will be assumed to be a Perl program and run passing its own basename in as an argument. This basename is actually a build target, and there is an intention, but not a requirement, that the *.PL file make the file passed to to as an argument. For example...</p>

<pre><code class="plaintext">perl foo.PL foo</code></pre>

<p>This behavior can be overridden by supplying your own set of files to search. PL_FILES accepts a hash ref, the key being the file to run and the value is passed in as the first argument when the PL file is run.</p>

<pre><code class="plaintext">PL_FILES =&gt; {&#39;bin/foobar.PL&#39; =&gt; &#39;bin/foobar&#39;}

PL_FILES =&gt; {&#39;foo.PL&#39; =&gt; &#39;foo.c&#39;}</code></pre>

<p>Would run bin/foobar.PL like this:</p>

<pre><code class="plaintext">perl bin/foobar.PL bin/foobar</code></pre>

<p>If multiple files from one program are desired an array ref can be used.</p>

<pre><code class="plaintext">PL_FILES =&gt; {&#39;bin/foobar.PL&#39; =&gt; [qw(bin/foobar1 bin/foobar2)]}</code></pre>

<p>In this case the program will be run multiple times using each target file.</p>

<pre><code class="plaintext">perl bin/foobar.PL bin/foobar1
perl bin/foobar.PL bin/foobar2</code></pre>

<p>If an output file depends on extra input files beside the script itself, a hash ref can be used in version 7.36 and above:</p>

<pre><code>PL_FILES =&gt; { &#39;foo.PL&#39; =&gt; {
    &#39;foo.out&#39; =&gt; &#39;foo.in&#39;,
    &#39;bar.out&#39; =&gt; [qw(bar1.in bar2.in)],
}</code></pre>

<p>In this case the extra input files will be passed to the program after the target file:</p>

<pre><code class="plaintext">perl foo.PL foo.out foo.in
perl foo.PL bar.out bar1.in bar2.in</code></pre>

<p>PL files are normally run <b>after</b> pm_to_blib and include INST_LIB and INST_ARCH in their <code>@INC</code>, so the just built modules can be accessed... unless the PL file is making a module (or anything else in PM) in which case it is run <b>before</b> pm_to_blib and does not include INST_LIB and INST_ARCH in its <code>@INC</code>. This apparently odd behavior is there for backwards compatibility (and it&#39;s somewhat DWIM). The argument passed to the .PL is set up as a target to build in the Makefile. In other sections such as <code>postamble</code> you can specify a dependency on the filename/argument that the .PL is supposed (or will have, now that that is is a dependency) to generate. Note the file to be generated will still be generated and the .PL will still run even without an explicit dependency created by you, since the <code>all</code> target still depends on running all eligible to run.PL files.</p>

</dd>
<dt id="PM"><a class="permalink" href="./ExtUtils::MakeMaker.html#PM">#</a>PM</dt>
<dd>

<p>Hashref of .pm files and *.pl files to be installed. e.g.</p>

<pre><code class="plaintext">{&#39;name_of_file.pm&#39; =&gt; &#39;$(INST_LIB)/install_as.pm&#39;}</code></pre>

<p>By default this will include *.pm and *.pl and the files found in the PMLIBDIRS directories. Defining PM in the Makefile.PL will override PMLIBDIRS.</p>

</dd>
<dt id="PMLIBDIRS"><a class="permalink" href="./ExtUtils::MakeMaker.html#PMLIBDIRS">#</a>PMLIBDIRS</dt>
<dd>

<p>Ref to array of subdirectories containing library files. Defaults to [ &#39;lib&#39;, $(BASEEXT) ]. The directories will be scanned and <i>any</i> files they contain will be installed in the corresponding location in the library. A libscan() method can be used to alter the behaviour. Defining PM in the Makefile.PL will override PMLIBDIRS.</p>

<p>(Where BASEEXT is the last component of NAME.)</p>

</dd>
<dt id="PM_FILTER"><a class="permalink" href="./ExtUtils::MakeMaker.html#PM_FILTER">#</a>PM_FILTER</dt>
<dd>

<p>A filter program, in the traditional Unix sense (input from stdin, output to stdout) that is passed on each .pm file during the build (in the pm_to_blib() phase). It is empty by default, meaning no filtering is done. You could use:</p>

<pre><code class="plaintext">PM_FILTER =&gt; &#39;perl -ne &quot;print unless /^\\#/&quot;&#39;,</code></pre>

<p>to remove all the leading comments on the fly during the build. In order to be as portable as possible, please consider using a Perl one-liner rather than Unix (or other) utilities, as above. The # is escaped for the Makefile, since what is going to be generated will then be:</p>

<pre><code class="plaintext">PM_FILTER = perl -ne &quot;print unless /^\#/&quot;</code></pre>

<p>Without the \ before the #, we&#39;d have the start of a Makefile comment, and the macro would be incorrectly defined.</p>

<p>You will almost certainly be better off using the <code>PL_FILES</code> system, instead. See above, or the <a href="./ExtUtils::MakeMaker::FAQ.html">ExtUtils::MakeMaker::FAQ</a> entry.</p>

</dd>
<dt id="POLLUTE"><a class="permalink" href="./ExtUtils::MakeMaker.html#POLLUTE">#</a>POLLUTE</dt>
<dd>

<p>Release 5.005 grandfathered old global symbol names by providing preprocessor macros for extension source compatibility. As of release 5.6, these preprocessor definitions are not available by default. The POLLUTE flag specifies that the old names should still be defined:</p>

<pre><code class="plaintext">perl Makefile.PL POLLUTE=1</code></pre>

<p>Please inform the module author if this is necessary to successfully install a module under 5.6 or later.</p>

</dd>
<dt id="PPM_INSTALL_EXEC"><a class="permalink" href="./ExtUtils::MakeMaker.html#PPM_INSTALL_EXEC">#</a>PPM_INSTALL_EXEC</dt>
<dd>

<p>Name of the executable used to run <code>PPM_INSTALL_SCRIPT</code> below. (e.g. perl)</p>

</dd>
<dt id="PPM_INSTALL_SCRIPT"><a class="permalink" href="./ExtUtils::MakeMaker.html#PPM_INSTALL_SCRIPT">#</a>PPM_INSTALL_SCRIPT</dt>
<dd>

<p>Name of the script that gets executed by the Perl Package Manager after the installation of a package.</p>

</dd>
<dt id="PPM_UNINSTALL_EXEC"><a class="permalink" href="./ExtUtils::MakeMaker.html#PPM_UNINSTALL_EXEC">#</a>PPM_UNINSTALL_EXEC</dt>
<dd>

<p>Available in version 6.8502 and above.</p>

<p>Name of the executable used to run <code>PPM_UNINSTALL_SCRIPT</code> below. (e.g. perl)</p>

</dd>
<dt id="PPM_UNINSTALL_SCRIPT"><a class="permalink" href="./ExtUtils::MakeMaker.html#PPM_UNINSTALL_SCRIPT">#</a>PPM_UNINSTALL_SCRIPT</dt>
<dd>

<p>Available in version 6.8502 and above.</p>

<p>Name of the script that gets executed by the Perl Package Manager before the removal of a package.</p>

</dd>
<dt id="PREFIX"><a class="permalink" href="./ExtUtils::MakeMaker.html#PREFIX">#</a>PREFIX</dt>
<dd>

<p>This overrides all the default install locations. Man pages, libraries, scripts, etc... MakeMaker will try to make an educated guess about where to place things under the new PREFIX based on your Config defaults. Failing that, it will fall back to a structure which should be sensible for your platform.</p>

<p>If you specify LIB or any INSTALL* variables they will not be affected by the PREFIX.</p>

</dd>
<dt id="PREREQ_FATAL"><a class="permalink" href="./ExtUtils::MakeMaker.html#PREREQ_FATAL">#</a>PREREQ_FATAL</dt>
<dd>

<p>Bool. If this parameter is true, failing to have the required modules (or the right versions thereof) will be fatal. <code>perl Makefile.PL</code> will <code>die</code> instead of simply informing the user of the missing dependencies.</p>

<p>It is <i>extremely</i> rare to have to use <code>PREREQ_FATAL</code>. Its use by module authors is <i>strongly discouraged</i> and should never be used lightly.</p>

<p>For dependencies that are required in order to run <code>Makefile.PL</code>, see <code>CONFIGURE_REQUIRES</code>.</p>

<p>Module installation tools have ways of resolving unmet dependencies but to do that they need a <i>Makefile</i>. Using <code>PREREQ_FATAL</code> breaks this. That&#39;s bad.</p>

<p>Assuming you have good test coverage, your tests should fail with missing dependencies informing the user more strongly that something is wrong. You can write a <i>t/00compile.t</i> test which will simply check that your code compiles and stop &quot;make test&quot; prematurely if it doesn&#39;t. See <a href="./Test::More.html#BAIL_OUT">&quot;BAIL_OUT&quot; in Test::More</a> for more details.</p>

</dd>
<dt id="PREREQ_PM"><a class="permalink" href="./ExtUtils::MakeMaker.html#PREREQ_PM">#</a>PREREQ_PM</dt>
<dd>

<p>A hash of modules that are needed to run your module. The keys are the module names ie. Test::More, and the minimum version is the value. If the required version number is 0 any version will do. The versions given may be a Perl v-string (see <a href="version.html">version</a>) or a range (see <a href="./CPAN::Meta::Requirements.html">CPAN::Meta::Requirements</a>).</p>

<p>This will go into the <code>requires</code> field of your <i>META.yml</i> and the <code>runtime</code> of the <code>prereqs</code> field of your <i>META.json</i>.</p>

<pre><code>PREREQ_PM =&gt; {
    # Require Test::More at least 0.47
    &quot;Test::More&quot; =&gt; &quot;0.47&quot;,

    # Require any version of Acme::Buffy
    &quot;Acme::Buffy&quot; =&gt; 0,
}</code></pre>

</dd>
<dt id="PREREQ_PRINT"><a class="permalink" href="./ExtUtils::MakeMaker.html#PREREQ_PRINT">#</a>PREREQ_PRINT</dt>
<dd>

<p>Bool. If this parameter is true, the prerequisites will be printed to stdout and MakeMaker will exit. The output format is an evalable hash ref.</p>

<pre><code>$PREREQ_PM = {
               &#39;A::B&#39; =&gt; Vers1,
               &#39;C::D&#39; =&gt; Vers2,
               ...
             };</code></pre>

<p>If a distribution defines a minimal required perl version, this is added to the output as an additional line of the form:</p>

<pre><code>$MIN_PERL_VERSION = &#39;5.008001&#39;;</code></pre>

<p>If BUILD_REQUIRES is not empty, it will be dumped as $BUILD_REQUIRES hashref.</p>

</dd>
<dt id="PRINT_PREREQ"><a class="permalink" href="./ExtUtils::MakeMaker.html#PRINT_PREREQ">#</a>PRINT_PREREQ</dt>
<dd>

<p>RedHatism for <code>PREREQ_PRINT</code>. The output format is different, though:</p>

<pre><code class="plaintext">perl(A::B)&gt;=Vers1 perl(C::D)&gt;=Vers2 ...</code></pre>

<p>A minimal required perl version, if present, will look like this:</p>

<pre><code class="plaintext">perl(perl)&gt;=5.008001</code></pre>

</dd>
<dt id="SITEPREFIX"><a class="permalink" href="./ExtUtils::MakeMaker.html#SITEPREFIX">#</a>SITEPREFIX</dt>
<dd>

<p>Like PERLPREFIX, but only for the site install locations.</p>

<p>Defaults to $Config{siteprefixexp}. Perls prior to 5.6.0 didn&#39;t have an explicit siteprefix in the Config. In those cases $Config{installprefix} will be used.</p>

<p>Overridable by PREFIX</p>

</dd>
<dt id="SIGN"><a class="permalink" href="./ExtUtils::MakeMaker.html#SIGN">#</a>SIGN</dt>
<dd>

<p>Available in version 6.18 and above.</p>

<p>When true, perform the generation and addition to the MANIFEST of the SIGNATURE file in the distdir during &#39;make distdir&#39;, via &#39;cpansign -s&#39;.</p>

<p>Note that you need to install the Module::Signature module to perform this operation.</p>

<p>Defaults to false.</p>

</dd>
<dt id="SKIP"><a class="permalink" href="./ExtUtils::MakeMaker.html#SKIP">#</a>SKIP</dt>
<dd>

<p>Arrayref. E.g. [qw(name1 name2)] skip (do not write) sections of the Makefile. Caution! Do not use the SKIP attribute for the negligible speedup. It may seriously damage the resulting Makefile. Only use it if you really need it.</p>

</dd>
<dt id="TEST_REQUIRES"><a class="permalink" href="./ExtUtils::MakeMaker.html#TEST_REQUIRES">#</a>TEST_REQUIRES</dt>
<dd>

<p>Available in version 6.64 and above.</p>

<p>A hash of modules that are needed to test your module but not run or build it.</p>

<p>This will go into the <code>build_requires</code> field of your <i>META.yml</i> and the <code>test</code> of the <code>prereqs</code> field of your <i>META.json</i>.</p>

<p>The format is the same as PREREQ_PM.</p>

</dd>
<dt id="TYPEMAPS"><a class="permalink" href="./ExtUtils::MakeMaker.html#TYPEMAPS">#</a>TYPEMAPS</dt>
<dd>

<p>Ref to array of typemap file names. Use this when the typemaps are in some directory other than the current directory or when they are not named <b>typemap</b>. The last typemap in the list takes precedence. A typemap in the current directory has highest precedence, even if it isn&#39;t listed in TYPEMAPS. The default system typemap has lowest precedence.</p>

</dd>
<dt id="VENDORPREFIX"><a class="permalink" href="./ExtUtils::MakeMaker.html#VENDORPREFIX">#</a>VENDORPREFIX</dt>
<dd>

<p>Like PERLPREFIX, but only for the vendor install locations.</p>

<p>Defaults to $Config{vendorprefixexp}.</p>

<p>Overridable by PREFIX</p>

</dd>
<dt id="VERBINST"><a class="permalink" href="./ExtUtils::MakeMaker.html#VERBINST">#</a>VERBINST</dt>
<dd>

<p>If true, make install will be verbose</p>

</dd>
<dt id="VERSION"><a class="permalink" href="./ExtUtils::MakeMaker.html#VERSION">#</a>VERSION</dt>
<dd>

<p>Your version number for distributing the package. This defaults to 0.1.</p>

</dd>
<dt id="VERSION_FROM"><a class="permalink" href="./ExtUtils::MakeMaker.html#VERSION_FROM">#</a>VERSION_FROM</dt>
<dd>

<p>Instead of specifying the VERSION in the Makefile.PL you can let MakeMaker parse a file to determine the version number. The parsing routine requires that the file named by VERSION_FROM contains one single line to compute the version number. The first line in the file that contains something like a $VERSION assignment or <code>package Name VERSION</code> will be used. The following lines will be parsed o.k.:</p>

<pre><code># Good
package Foo::Bar 1.23;                      # 1.23
$VERSION   = &#39;1.00&#39;;                        # 1.00
*VERSION   = \&#39;1.01&#39;;                       # 1.01
($VERSION) = q$Revision$ =~ /(\d+)/g;       # The digits in $Revision$
$FOO::VERSION = &#39;1.10&#39;;                     # 1.10
*FOO::VERSION = \&#39;1.11&#39;;                    # 1.11</code></pre>

<p>but these will fail:</p>

<pre><code># Bad
my $VERSION         = &#39;1.01&#39;;
local $VERSION      = &#39;1.02&#39;;
local $FOO::VERSION = &#39;1.30&#39;;</code></pre>

<p>(Putting <code>my</code> or <code>local</code> on the preceding line will work o.k.)</p>

<p>&quot;Version strings&quot; are incompatible and should not be used.</p>

<pre><code># Bad
$VERSION = 1.2.3;
$VERSION = v1.2.3;</code></pre>

<p><a href="version.html">version</a> objects are fine. As of MakeMaker 6.35 version.pm will be automatically loaded, but you must declare the dependency on version.pm. For compatibility with older MakeMaker you should load on the same line as $VERSION is declared.</p>

<pre><code># All on one line
use version; our $VERSION = qv(1.2.3);</code></pre>

<p>The file named in VERSION_FROM is not added as a dependency to Makefile. This is not really correct, but it would be a major pain during development to have to rewrite the Makefile for any smallish change in that file. If you want to make sure that the Makefile contains the correct VERSION macro after any change of the file, you would have to do something like</p>

<pre><code class="plaintext">depend =&gt; { Makefile =&gt; &#39;$(VERSION_FROM)&#39; }</code></pre>

<p>See attribute <code>depend</code> below.</p>

</dd>
<dt id="VERSION_SYM"><a class="permalink" href="./ExtUtils::MakeMaker.html#VERSION_SYM">#</a>VERSION_SYM</dt>
<dd>

<p>A sanitized VERSION with . replaced by _. For places where . has special meaning (some filesystems, RCS labels, etc...)</p>

</dd>
<dt id="XS"><a class="permalink" href="./ExtUtils::MakeMaker.html#XS">#</a>XS</dt>
<dd>

<p>Hashref of .xs files. MakeMaker will default this. e.g.</p>

<pre><code class="plaintext">{&#39;name_of_file.xs&#39; =&gt; &#39;name_of_file.c&#39;}</code></pre>

<p>The .c files will automatically be included in the list of files deleted by a make clean.</p>

</dd>
<dt id="XSBUILD"><a class="permalink" href="./ExtUtils::MakeMaker.html#XSBUILD">#</a>XSBUILD</dt>
<dd>

<p>Available in version 7.12 and above.</p>

<p>Hashref with options controlling the operation of <code>XSMULTI</code>:</p>

<pre><code>{
  xs =&gt; {
      all =&gt; {
          # options applying to all .xs files for this distribution
      },
      &#39;lib/Class/Name/File&#39; =&gt; { # specifically for this file
          DEFINE =&gt; &#39;-Dfunktastic&#39;, # defines for only this file
          INC =&gt; &quot;-I$funkyliblocation&quot;, # include flags for only this file
          # OBJECT =&gt; &#39;lib/Class/Name/File$(OBJ_EXT)&#39;, # default
          LDFROM =&gt; &quot;lib/Class/Name/File\$(OBJ_EXT) $otherfile\$(OBJ_EXT)&quot;, # what&#39;s linked
      },
  },
}</code></pre>

<p>Note <code>xs</code> is the file-extension. More possibilities may arise in the future. Note that object names are specified without their XS extension.</p>

<p><code>LDFROM</code> defaults to the same as <code>OBJECT</code>. <code>OBJECT</code> defaults to, for <code>XSMULTI</code>, just the XS filename with the extension replaced with the compiler-specific object-file extension.</p>

<p>The distinction between <code>OBJECT</code> and <code>LDFROM</code>: <code>OBJECT</code> is the make target, so make will try to build it. However, <code>LDFROM</code> is what will actually be linked together to make the shared object or static library (SO/SL), so if you override it, make sure it includes what you want to make the final SO/SL, almost certainly including the XS basename with <code>$(OBJ_EXT)</code> appended.</p>

</dd>
<dt id="XSMULTI"><a class="permalink" href="./ExtUtils::MakeMaker.html#XSMULTI">#</a>XSMULTI</dt>
<dd>

<p>Available in version 7.12 and above.</p>

<p>When this is set to <code>1</code>, multiple XS files may be placed under <i>lib/</i> next to their corresponding <code>*.pm</code> files (this is essential for compiling with the correct <code>VERSION</code> values). This feature should be considered experimental, and details of it may change.</p>

<p>This feature was inspired by, and small portions of code copied from, <a href="./ExtUtils::MakeMaker::BigHelper.html">ExtUtils::MakeMaker::BigHelper</a>. Hopefully this feature will render that module mainly obsolete.</p>

</dd>
<dt id="XSOPT"><a class="permalink" href="./ExtUtils::MakeMaker.html#XSOPT">#</a>XSOPT</dt>
<dd>

<p>String of options to pass to xsubpp. This might include <code>-C++</code> or <code>-extern</code>. Do not include typemaps here; the TYPEMAP parameter exists for that purpose.</p>

</dd>
<dt id="XSPROTOARG"><a class="permalink" href="./ExtUtils::MakeMaker.html#XSPROTOARG">#</a>XSPROTOARG</dt>
<dd>

<p>May be set to <code>-prototypes</code>, <code>-noprototypes</code> or the empty string. The empty string is equivalent to the xsubpp default, or <code>-noprototypes</code>. See the xsubpp documentation for details. MakeMaker defaults to the empty string.</p>

</dd>
<dt id="XS_VERSION"><a class="permalink" href="./ExtUtils::MakeMaker.html#XS_VERSION">#</a>XS_VERSION</dt>
<dd>

<p>Your version number for the .xs file of this package. This defaults to the value of the VERSION attribute.</p>

</dd>
</dl>

<h2 id="Additional-lowercase-attributes"><a class="permalink" href="./ExtUtils::MakeMaker.html#Additional-lowercase-attributes">#</a><a id="Additional"></a>Additional lowercase attributes</h2>

<p>can be used to pass parameters to the methods which implement that part of the Makefile. Parameters are specified as a hash ref but are passed to the method as a hash.</p>

<dl>

<dt id="clean"><a class="permalink" href="./ExtUtils::MakeMaker.html#clean">#</a>clean</dt>
<dd>

<pre><code class="plaintext">{FILES =&gt; &quot;*.xyz foo&quot;}</code></pre>

</dd>
<dt id="depend"><a class="permalink" href="./ExtUtils::MakeMaker.html#depend">#</a>depend</dt>
<dd>

<pre><code class="plaintext">{ANY_TARGET =&gt; ANY_DEPENDENCY, ...}</code></pre>

<p>(ANY_TARGET must not be given a double-colon rule by MakeMaker.)</p>

</dd>
<dt id="dist"><a class="permalink" href="./ExtUtils::MakeMaker.html#dist">#</a>dist</dt>
<dd>

<pre><code class="plaintext">{TARFLAGS =&gt; &#39;cvfF&#39;, COMPRESS =&gt; &#39;gzip&#39;, SUFFIX =&gt; &#39;.gz&#39;,
SHAR =&gt; &#39;shar -m&#39;, DIST_CP =&gt; &#39;ln&#39;, ZIP =&gt; &#39;/bin/zip&#39;,
ZIPFLAGS =&gt; &#39;-rl&#39;, DIST_DEFAULT =&gt; &#39;private tardist&#39; }</code></pre>

<p>If you specify COMPRESS, then SUFFIX should also be altered, as it is needed to tell make the target file of the compression. Setting DIST_CP to ln can be useful, if you need to preserve the timestamps on your files. DIST_CP can take the values &#39;cp&#39;, which copies the file, &#39;ln&#39;, which links the file, and &#39;best&#39; which copies symbolic links and links the rest. Default is &#39;best&#39;.</p>

</dd>
<dt id="dynamic_lib"><a class="permalink" href="./ExtUtils::MakeMaker.html#dynamic_lib">#</a>dynamic_lib</dt>
<dd>

<pre><code class="plaintext">{ARMAYBE =&gt; &#39;ar&#39;, OTHERLDFLAGS =&gt; &#39;...&#39;, INST_DYNAMIC_DEP =&gt; &#39;...&#39;}</code></pre>

</dd>
<dt id="linkext"><a class="permalink" href="./ExtUtils::MakeMaker.html#linkext">#</a>linkext</dt>
<dd>

<pre><code class="plaintext">{LINKTYPE =&gt; &#39;static&#39;, &#39;dynamic&#39; or &#39;&#39;}</code></pre>

<p>NB: Extensions that have nothing but *.pm files had to say</p>

<pre><code class="plaintext">{LINKTYPE =&gt; &#39;&#39;}</code></pre>

<p>with Pre-5.0 MakeMakers. Since version 5.00 of MakeMaker such a line can be deleted safely. MakeMaker recognizes when there&#39;s nothing to be linked.</p>

</dd>
<dt id="macro"><a class="permalink" href="./ExtUtils::MakeMaker.html#macro">#</a>macro</dt>
<dd>

<pre><code class="plaintext">{ANY_MACRO =&gt; ANY_VALUE, ...}</code></pre>

</dd>
<dt id="postamble"><a class="permalink" href="./ExtUtils::MakeMaker.html#postamble">#</a>postamble</dt>
<dd>

<p>Anything put here will be passed to <a href="./ExtUtils::MM_Any.html#postamble-%28o%29">MY::postamble()</a> if you have one.</p>

</dd>
<dt id="realclean"><a class="permalink" href="./ExtUtils::MakeMaker.html#realclean">#</a>realclean</dt>
<dd>

<pre><code class="plaintext">{FILES =&gt; &#39;$(INST_ARCHAUTODIR)/*.xyz&#39;}</code></pre>

</dd>
<dt id="test"><a class="permalink" href="./ExtUtils::MakeMaker.html#test">#</a>test</dt>
<dd>

<p>Specify the targets for testing.</p>

<pre><code class="plaintext">{TESTS =&gt; &#39;t/*.t&#39;}</code></pre>

<p><code>RECURSIVE_TEST_FILES</code> can be used to include all directories recursively under <code>t</code> that contain <code>.t</code> files. It will be ignored if you provide your own <code>TESTS</code> attribute, defaults to false.</p>

<pre><code class="plaintext">{RECURSIVE_TEST_FILES=&gt;1}</code></pre>

<p>This is supported since 6.76</p>

</dd>
<dt id="tool_autosplit"><a class="permalink" href="./ExtUtils::MakeMaker.html#tool_autosplit">#</a>tool_autosplit</dt>
<dd>

<pre><code class="plaintext">{MAXLEN =&gt; 8}</code></pre>

</dd>
</dl>

<h2 id="Overriding-MakeMaker-Methods"><a class="permalink" href="./ExtUtils::MakeMaker.html#Overriding-MakeMaker-Methods">#</a><a id="Overriding"></a>Overriding MakeMaker Methods</h2>

<p>If you cannot achieve the desired Makefile behaviour by specifying attributes you may define private subroutines in the Makefile.PL. Each subroutine returns the text it wishes to have written to the Makefile. To override a section of the Makefile you can either say:</p>

<pre><code class="plaintext">sub MY::c_o { &quot;new literal text&quot; }</code></pre>

<p>or you can edit the default by saying something like:</p>

<pre><code>package MY; # so that &quot;SUPER&quot; works right
sub c_o {
    my $inherited = shift-&gt;SUPER::c_o(@_);
    $inherited =~ s/old text/new text/;
    $inherited;
}</code></pre>

<p>If you are running experiments with embedding perl as a library into other applications, you might find MakeMaker is not sufficient. You&#39;d better have a look at <a href="./ExtUtils::Embed.html">ExtUtils::Embed</a> which is a collection of utilities for embedding.</p>

<p>If you still need a different solution, try to develop another subroutine that fits your needs and submit the diffs to <code>makemaker@perl.org</code></p>

<p>For a complete description of all MakeMaker methods see <a href="./ExtUtils::MM_Unix.html">ExtUtils::MM_Unix</a>.</p>

<p>Here is a simple example of how to add a new target to the generated Makefile:</p>

<pre><code>sub MY::postamble {
    return &lt;&lt;&#39;MAKE_FRAG&#39;;
$(MYEXTLIB): sdbm/Makefile
        cd sdbm &amp;&amp; $(MAKE) all

MAKE_FRAG
}</code></pre>

<h2 id="The-End-Of-Cargo-Cult-Programming"><a class="permalink" href="./ExtUtils::MakeMaker.html#The-End-Of-Cargo-Cult-Programming">#</a><a id="The"></a>The End Of Cargo Cult Programming</h2>

<p>WriteMakefile() now does some basic sanity checks on its parameters to protect against typos and malformatted values. This means some things which happened to work in the past will now throw warnings and possibly produce internal errors.</p>

<p>Some of the most common mistakes:</p>

<dl>

<dt id="MAN3PODS-=&gt;-&#39;-&#39;"><a class="permalink" href="./ExtUtils::MakeMaker.html#MAN3PODS-=%3E-&#39;-&#39;">#</a><a id="MAN3PODS1"></a><code>MAN3PODS =&gt; &#39; &#39;</code></dt>
<dd>

<p>This is commonly used to suppress the creation of man pages. MAN3PODS takes a hash ref not a string, but the above worked by accident in old versions of MakeMaker.</p>

<p>The correct code is <code>MAN3PODS =&gt; { }</code>.</p>

</dd>
</dl>

<h2 id="Hintsfile-support"><a class="permalink" href="./ExtUtils::MakeMaker.html#Hintsfile-support">#</a><a id="Hintsfile"></a>Hintsfile support</h2>

<p>MakeMaker.pm uses the architecture-specific information from Config.pm. In addition it evaluates architecture specific hints files in a <code>hints/</code> directory. The hints files are expected to be named like their counterparts in <code>PERL_SRC/hints</code>, but with an <code>.pl</code> file name extension (eg. <code>next_3_2.pl</code>). They are simply <code>eval</code>ed by MakeMaker within the WriteMakefile() subroutine, and can be used to execute commands as well as to include special variables. The rules which hintsfile is chosen are the same as in Configure.</p>

<p>The hintsfile is eval()ed immediately after the arguments given to WriteMakefile are stuffed into a hash reference $self but before this reference becomes blessed. So if you want to do the equivalent to override or create an attribute you would say something like</p>

<pre><code>$self-&gt;{LIBS} = [&#39;-ldbm -lucb -lc&#39;];</code></pre>

<h2 id="Distribution-Support"><a class="permalink" href="./ExtUtils::MakeMaker.html#Distribution-Support">#</a><a id="Distribution"></a>Distribution Support</h2>

<p>For authors of extensions MakeMaker provides several Makefile targets. Most of the support comes from the <a href="./ExtUtils::Manifest.html">ExtUtils::Manifest</a> module, where additional documentation can be found.</p>

<dl>

<dt id="make-distcheck"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-distcheck">#</a><a id="make3"></a>make distcheck</dt>
<dd>

<p>reports which files are below the build directory but not in the MANIFEST file and vice versa. (See <a href="./ExtUtils::Manifest.html#fullcheck">&quot;fullcheck&quot; in ExtUtils::Manifest</a> for details)</p>

</dd>
<dt id="make-skipcheck"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-skipcheck">#</a><a id="make4"></a>make skipcheck</dt>
<dd>

<p>reports which files are skipped due to the entries in the <code>MANIFEST.SKIP</code> file (See <a href="./ExtUtils::Manifest.html#skipcheck">&quot;skipcheck&quot; in ExtUtils::Manifest</a> for details)</p>

</dd>
<dt id="make-distclean"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-distclean">#</a><a id="make5"></a>make distclean</dt>
<dd>

<p>does a realclean first and then the distcheck. Note that this is not needed to build a new distribution as long as you are sure that the MANIFEST file is ok.</p>

</dd>
<dt id="make-veryclean"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-veryclean">#</a><a id="make6"></a>make veryclean</dt>
<dd>

<p>does a realclean first and then removes backup files such as <code>*~</code>, <code>*.bak</code>, <code>*.old</code> and <code>*.orig</code></p>

</dd>
<dt id="make-manifest"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-manifest">#</a><a id="make7"></a>make manifest</dt>
<dd>

<p>rewrites the MANIFEST file, adding all remaining files found (See <a href="./ExtUtils::Manifest.html#mkmanifest">&quot;mkmanifest&quot; in ExtUtils::Manifest</a> for details)</p>

</dd>
<dt id="make-distdir"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-distdir">#</a><a id="make8"></a>make distdir</dt>
<dd>

<p>Copies all the files that are in the MANIFEST file to a newly created directory with the name <code>$(DISTNAME)-$(VERSION)</code>. If that directory exists, it will be removed first.</p>

<p>Additionally, it will create META.yml and META.json module meta-data file in the distdir and add this to the distdir&#39;s MANIFEST. You can shut this behavior off with the NO_META flag.</p>

</dd>
<dt id="make-disttest"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-disttest">#</a><a id="make9"></a>make disttest</dt>
<dd>

<p>Makes a distdir first, and runs a <code>perl Makefile.PL</code>, a make, and a make test in that directory.</p>

</dd>
<dt id="make-tardist"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-tardist">#</a><a id="make10"></a>make tardist</dt>
<dd>

<p>First does a distdir. Then a command $(PREOP) which defaults to a null command, followed by $(TO_UNIX), which defaults to a null command under UNIX, and will convert files in distribution directory to UNIX format otherwise. Next it runs <code>tar</code> on that directory into a tarfile and deletes the directory. Finishes with a command $(POSTOP) which defaults to a null command.</p>

</dd>
<dt id="make-dist"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-dist">#</a><a id="make11"></a>make dist</dt>
<dd>

<p>Defaults to $(DIST_DEFAULT) which in turn defaults to tardist.</p>

</dd>
<dt id="make-uutardist"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-uutardist">#</a><a id="make12"></a>make uutardist</dt>
<dd>

<p>Runs a tardist first and uuencodes the tarfile.</p>

</dd>
<dt id="make-shdist"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-shdist">#</a><a id="make13"></a>make shdist</dt>
<dd>

<p>First does a distdir. Then a command $(PREOP) which defaults to a null command. Next it runs <code>shar</code> on that directory into a sharfile and deletes the intermediate directory again. Finishes with a command $(POSTOP) which defaults to a null command. Note: For shdist to work properly a <code>shar</code> program that can handle directories is mandatory.</p>

</dd>
<dt id="make-zipdist"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-zipdist">#</a><a id="make14"></a>make zipdist</dt>
<dd>

<p>First does a distdir. Then a command $(PREOP) which defaults to a null command. Runs <code>$(ZIP) $(ZIPFLAGS)</code> on that directory into a zipfile. Then deletes that directory. Finishes with a command $(POSTOP) which defaults to a null command.</p>

</dd>
<dt id="make-ci"><a class="permalink" href="./ExtUtils::MakeMaker.html#make-ci">#</a><a id="make15"></a>make ci</dt>
<dd>

<p>Does a $(CI) and a $(RCS_LABEL) on all files in the MANIFEST file.</p>

</dd>
</dl>

<p>Customization of the dist targets can be done by specifying a hash reference to the dist attribute of the WriteMakefile call. The following parameters are recognized:</p>

<pre><code class="plaintext">CI           (&#39;ci -u&#39;)
COMPRESS     (&#39;gzip --best&#39;)
POSTOP       (&#39;@ :&#39;)
PREOP        (&#39;@ :&#39;)
TO_UNIX      (depends on the system)
RCS_LABEL    (&#39;rcs -q -Nv$(VERSION_SYM):&#39;)
SHAR         (&#39;shar&#39;)
SUFFIX       (&#39;.gz&#39;)
TAR          (&#39;tar&#39;)
TARFLAGS     (&#39;cvf&#39;)
ZIP          (&#39;zip&#39;)
ZIPFLAGS     (&#39;-r&#39;)</code></pre>

<p>An example:</p>

<pre><code>WriteMakefile(
    ...other options...
    dist =&gt; {
        COMPRESS =&gt; &quot;bzip2&quot;,
        SUFFIX   =&gt; &quot;.bz2&quot;
    }
);</code></pre>

<h2 id="Module-Meta-Data-(META-and-MYMETA)"><a class="permalink" href="./ExtUtils::MakeMaker.html#Module-Meta-Data-(META-and-MYMETA)">#</a><a id="Module"></a><a id="Module-Meta-Data-META-and-MYMETA"></a>Module Meta-Data (META and MYMETA)</h2>

<p>Long plaguing users of MakeMaker based modules has been the problem of getting basic information about the module out of the sources <i>without</i> running the <i>Makefile.PL</i> and doing a bunch of messy heuristics on the resulting <i>Makefile</i>. Over the years, it has become standard to keep this information in one or more CPAN Meta files distributed with each distribution.</p>

<p>The original format of CPAN Meta files was <a href="YAML.html">YAML</a> and the corresponding file was called <i>META.yml</i>. In 2010, version 2 of the <a href="./CPAN::Meta::Spec.html">CPAN::Meta::Spec</a> was released, which mandates JSON format for the metadata in order to overcome certain compatibility issues between YAML serializers and to avoid breaking older clients unable to handle a new version of the spec. The <a href="./CPAN::Meta.html">CPAN::Meta</a> library is now standard for accessing old and new-style Meta files.</p>

<p>If <a href="./CPAN::Meta.html">CPAN::Meta</a> is installed, MakeMaker will automatically generate <i>META.json</i> and <i>META.yml</i> files for you and add them to your <i>MANIFEST</i> as part of the &#39;distdir&#39; target (and thus the &#39;dist&#39; target). This is intended to seamlessly and rapidly populate CPAN with module meta-data. If you wish to shut this feature off, set the <code>NO_META</code> <code>WriteMakefile()</code> flag to true.</p>

<p>At the 2008 QA Hackathon in Oslo, Perl module toolchain maintainers agreed to use the CPAN Meta format to communicate post-configuration requirements between toolchain components. These files, <i>MYMETA.json</i> and <i>MYMETA.yml</i>, are generated when <i>Makefile.PL</i> generates a <i>Makefile</i> (if <a href="./CPAN::Meta.html">CPAN::Meta</a> is installed). Clients like <a href="CPAN.html">CPAN</a> or <a href="CPANPLUS.html">CPANPLUS</a> will read these files to see what prerequisites must be fulfilled before building or testing the distribution. If you wish to shut this feature off, set the <code>NO_MYMETA</code> <code>WriteMakeFile()</code> flag to true.</p>

<h2 id="Disabling-an-extension"><a class="permalink" href="./ExtUtils::MakeMaker.html#Disabling-an-extension">#</a><a id="Disabling"></a>Disabling an extension</h2>

<p>If some events detected in <i>Makefile.PL</i> imply that there is no way to create the Module, but this is a normal state of things, then you can create a <i>Makefile</i> which does nothing, but succeeds on all the &quot;usual&quot; build targets. To do so, use</p>

<pre><code>use ExtUtils::MakeMaker qw(WriteEmptyMakefile);
WriteEmptyMakefile();</code></pre>

<p>instead of WriteMakefile().</p>

<p>This may be useful if other modules expect this module to be <i>built</i> OK, as opposed to <i>work</i> OK (say, this system-dependent module builds in a subdirectory of some other distribution, or is listed as a dependency in a CPAN::Bundle, but the functionality is supported by different means on the current architecture).</p>

<h2 id="Other-Handy-Functions"><a class="permalink" href="./ExtUtils::MakeMaker.html#Other-Handy-Functions">#</a><a id="Other"></a>Other Handy Functions</h2>

<dl>

<dt id="prompt"><a class="permalink" href="./ExtUtils::MakeMaker.html#prompt">#</a>prompt</dt>
<dd>

<pre><code>my $value = prompt($message);
my $value = prompt($message, $default);</code></pre>

<p>The <code>prompt()</code> function provides an easy way to request user input used to write a makefile. It displays the $message as a prompt for input. If a $default is provided it will be used as a default. The function returns the $value selected by the user.</p>

<p>If <code>prompt()</code> detects that it is not running interactively and there is nothing on STDIN or if the PERL_MM_USE_DEFAULT environment variable is set to true, the $default will be used without prompting. This prevents automated processes from blocking on user input.</p>

<p>If no $default is provided an empty string will be used instead.</p>

</dd>
<dt id="os_unsupported"><a class="permalink" href="./ExtUtils::MakeMaker.html#os_unsupported">#</a>os_unsupported</dt>
<dd>

<pre><code>os_unsupported();
os_unsupported if $^O eq &#39;MSWin32&#39;;</code></pre>

<p>The <code>os_unsupported()</code> function provides a way to correctly exit your <code>Makefile.PL</code> before calling <code>WriteMakefile</code>. It is essentially a <code>die</code> with the message &quot;OS unsupported&quot;.</p>

<p>This is supported since 7.26</p>

</dd>
</dl>

<h2 id="Supported-versions-of-Perl"><a class="permalink" href="./ExtUtils::MakeMaker.html#Supported-versions-of-Perl">#</a><a id="Supported"></a>Supported versions of Perl</h2>

<p>Please note that while this module works on Perl 5.6, it is no longer being routinely tested on 5.6 - the earliest Perl version being routinely tested, and expressly supported, is 5.8.1. However, patches to repair any breakage on 5.6 are still being accepted.</p>

<h1 id="ENVIRONMENT"><a class="permalink" href="./ExtUtils::MakeMaker.html#ENVIRONMENT">#</a>ENVIRONMENT</h1>

<dl>

<dt id="PERL_MM_OPT"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERL_MM_OPT">#</a>PERL_MM_OPT</dt>
<dd>

<p>Command line options used by <code>MakeMaker-&gt;new()</code>, and thus by <code>WriteMakefile()</code>. The string is split as the shell would, and the result is processed before any actual command line arguments are processed.</p>

<pre><code class="plaintext">PERL_MM_OPT=&#39;CCFLAGS=&quot;-Wl,-rpath -Wl,/foo/bar/lib&quot; LIBS=&quot;-lwibble -lwobble&quot;&#39;</code></pre>

</dd>
<dt id="PERL_MM_USE_DEFAULT"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERL_MM_USE_DEFAULT">#</a>PERL_MM_USE_DEFAULT</dt>
<dd>

<p>If set to a true value then MakeMaker&#39;s prompt function will always return the default without waiting for user input.</p>

</dd>
<dt id="PERL_CORE1"><a class="permalink" href="./ExtUtils::MakeMaker.html#PERL_CORE1">#</a>PERL_CORE</dt>
<dd>

<p>Same as the PERL_CORE parameter. The parameter overrides this.</p>

</dd>
</dl>

<h1 id="SEE-ALSO"><a class="permalink" href="./ExtUtils::MakeMaker.html#SEE-ALSO">#</a><a id="SEE"></a>SEE ALSO</h1>

<p><a href="./Module::Build.html">Module::Build</a> is a pure-Perl alternative to MakeMaker which does not rely on make or any other external utility. It may be easier to extend to suit your needs.</p>

<p><a href="./Module::Build::Tiny.html">Module::Build::Tiny</a> is a minimal pure-Perl alternative to MakeMaker that follows the Build.PL protocol of Module::Build but without its complexity and cruft, implementing only the installation of the module and leaving authoring to <a href="mbtiny.html">mbtiny</a> or other authoring tools.</p>

<p><a href="./Module::Install.html">Module::Install</a> is a (now discouraged) wrapper around MakeMaker which adds features not normally available.</p>

<p><a href="./ExtUtils::ModuleMaker.html">ExtUtils::ModuleMaker</a> and <a href="./Module::Starter.html">Module::Starter</a> are both modules to help you setup your distribution.</p>

<p><a href="./CPAN::Meta.html">CPAN::Meta</a> and <a href="./CPAN::Meta::Spec.html">CPAN::Meta::Spec</a> explain CPAN Meta files in detail.</p>

<p><a href="./File::ShareDir::Install.html">File::ShareDir::Install</a> makes it easy to install static, sometimes also referred to as &#39;shared&#39; files. <a href="./File::ShareDir.html">File::ShareDir</a> helps accessing the shared files after installation. <a href="./Test::File::ShareDir.html">Test::File::ShareDir</a> helps when writing tests to use the shared files both before and after installation.</p>

<p><a href="./Dist::Zilla.html">Dist::Zilla</a> is an authoring tool which allows great customization and extensibility of the author experience, relying on the existing install tools like ExtUtils::MakeMaker only for installation.</p>

<p><a href="./Dist::Milla.html">Dist::Milla</a> is a Dist::Zilla bundle that greatly simplifies common usage.</p>

<p><a href="Minilla.html">Minilla</a> is a minimal authoring tool that does the same things as Dist::Milla without the overhead of Dist::Zilla.</p>

<h1 id="AUTHORS"><a class="permalink" href="./ExtUtils::MakeMaker.html#AUTHORS">#</a>AUTHORS</h1>

<p>Andy Dougherty <code>doughera@lafayette.edu</code>, Andreas König <code>andreas.koenig@mind.de</code>, Tim Bunce <code>timb@cpan.org</code>. VMS support by Charles Bailey <code>bailey@newman.upenn.edu</code>. OS/2 support by Ilya Zakharevich <code>ilya@math.ohio-state.edu</code>.</p>

<p>Currently maintained by Michael G Schwern <code>schwern@pobox.com</code></p>

<p>Send patches and ideas to <code>makemaker@perl.org</code>.</p>

<p>Send bug reports via http://rt.cpan.org/. Please send your generated Makefile along with your report.</p>

<p>For more up-to-date information, see <a href="https://metacpan.org/release/ExtUtils-MakeMaker">https://metacpan.org/release/ExtUtils-MakeMaker</a>.</p>

<p>Repository available at <a href="https://github.com/Perl-Toolchain-Gang/ExtUtils-MakeMaker">https://github.com/Perl-Toolchain-Gang/ExtUtils-MakeMaker</a>.</p>

<h1 id="LICENSE1"><a class="permalink" href="./ExtUtils::MakeMaker.html#LICENSE1">#</a>LICENSE</h1>

<p>This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.</p>

<p>See <a href="http://www.perl.com/perl/misc/Artistic.html">http://www.perl.com/perl/misc/Artistic.html</a></p>


      </div>
      <div id="footer">
        <p>Perldoc Browser is maintained by Dan Book (<a href="https://metacpan.org/author/DBOOK">DBOOK</a>). Please contact him via the <a href="https://github.com/Grinnz/perldoc-browser/issues">GitHub issue tracker</a> or <a href="mailto:dbook@cpan.org">email</a> regarding any issues with the site itself, search, or rendering of documentation.</p>

<p>The Perl documentation is maintained by the Perl 5 Porters in the development of Perl. Please contact them via the <a href="https://github.com/Perl/perl5/issues">Perl issue tracker</a>, the <a href="https://lists.perl.org/list/perl5-porters.html">mailing list</a>, or <a href="https://kiwiirc.com/client/irc.perl.org/p5p">IRC</a> to report any issues with the contents or format of the documentation.</p>


      </div>
    </div>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.5.1/jquery.slim.min.js" integrity="sha512-/DXTXr6nQodMUiq+IUJYCt2PPOUjrHJ9wFrqpJ3XkgPNOZVfMok7cRw6CSxyCQxXn6ozlESsSh1/sMCTF1rL/g==" crossorigin="anonymous"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.16.1/umd/popper.min.js" integrity="sha512-ubuT8Z88WxezgSqf3RLuNi5lmjstiJcyezx34yIU2gAHonIi27Na7atqzUZCOoY4CExaoFumzOsFQ2Ch+I/HCw==" crossorigin="anonymous"></script>
    <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js" integrity="sha384-B4gt1jrGC7Jh4AgTPSdUtOBvfO8shuf57BaghqFfPlYxofvL8/KUEfYiJOMMV+rV" crossorigin="anonymous"></script>
    <script src="../highlight.pack.js"></script>
    <script>hljs.highlightAll();</script>
  </body>
</html>
